Skip to content

Commit f9517dc

Browse files
authored
Add documentation website (#101)
1 parent 041d760 commit f9517dc

7 files changed

Lines changed: 270 additions & 0 deletions

File tree

.github/workflows/CI.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,3 +40,30 @@ jobs:
4040
- uses: codecov/codecov-action@v3
4141
with:
4242
files: lcov.info
43+
docs:
44+
name: Documentation
45+
runs-on: ubuntu-latest
46+
permissions:
47+
contents: write
48+
statuses: write
49+
steps:
50+
- uses: actions/checkout@v3
51+
- uses: julia-actions/setup-julia@v1
52+
with:
53+
version: '1'
54+
- name: Configure doc environment
55+
run: |
56+
julia --project=docs/ -e '
57+
using Pkg
58+
Pkg.develop(PackageSpec(path=pwd()))
59+
Pkg.instantiate()'
60+
- uses: julia-actions/julia-buildpkg@v1
61+
- uses: julia-actions/julia-docdeploy@v1
62+
env:
63+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
64+
- run: |
65+
julia --project=docs -e '
66+
using Documenter: DocMeta, doctest
67+
using AbstractDifferentiation
68+
DocMeta.setdocmeta!(AbstractDifferentiation, :DocTestSetup, :(using AbstractDifferentiation); recursive=true)
69+
doctest(AbstractDifferentiation)'

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
11
/Manifest.toml
2+
/docs/build
3+
/docs/src/index.md

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# AbstractDifferentiation
22

3+
[![Stable](https://img.shields.io/badge/docs-stable-blue.svg)](https://JuliaDiff.github.io/AbstractDifferentiation.jl/stable)
4+
[![Dev](https://img.shields.io/badge/docs-dev-blue.svg)](https://JuliaDiff.github.io/AbstractDifferentiation.jl/dev)
35
[![CI](https://github.com/JuliaDiff/AbstractDifferentiation.jl/actions/workflows/CI.yml/badge.svg?branch=master)](https://github.com/JuliaDiff/AbstractDifferentiation.jl/actions/workflows/CI.yml?query=branch%3Amaster)
46
[![Coverage](https://codecov.io/gh/JuliaDiff/AbstractDifferentiation.jl/branch/master/graph/badge.svg)](https://codecov.io/gh/JuliaDiff/AbstractDifferentiation.jl)
57

docs/Manifest.toml

Lines changed: 178 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,178 @@
1+
# This file is machine-generated - editing it directly is not advised
2+
3+
julia_version = "1.9.2"
4+
manifest_format = "2.0"
5+
project_hash = "2ea368e6dfe17054675f1828ff2b2c55382ede29"
6+
7+
[[deps.ANSIColoredPrinters]]
8+
git-tree-sha1 = "574baf8110975760d391c710b6341da1afa48d8c"
9+
uuid = "a4c015fc-c6ff-483c-b24f-f7ea428134e9"
10+
version = "0.0.1"
11+
12+
[[deps.AbstractDifferentiation]]
13+
deps = ["ExprTools", "LinearAlgebra", "Requires"]
14+
path = ".."
15+
uuid = "c29ec348-61ec-40c8-8164-b8c60e9d9f3d"
16+
version = "0.5.2"
17+
18+
[deps.AbstractDifferentiation.extensions]
19+
AbstractDifferentiationChainRulesCoreExt = "ChainRulesCore"
20+
AbstractDifferentiationFiniteDifferencesExt = "FiniteDifferences"
21+
AbstractDifferentiationForwardDiffExt = ["DiffResults", "ForwardDiff"]
22+
AbstractDifferentiationReverseDiffExt = ["DiffResults", "ReverseDiff"]
23+
AbstractDifferentiationTrackerExt = "Tracker"
24+
AbstractDifferentiationZygoteExt = "Zygote"
25+
26+
[deps.AbstractDifferentiation.weakdeps]
27+
ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4"
28+
DiffResults = "163ba53b-c6d8-5494-b064-1a9d43ac40c5"
29+
FiniteDifferences = "26cc04aa-876d-5657-8c51-4c34ba976000"
30+
ForwardDiff = "f6369f11-7733-5829-9624-2563aa707210"
31+
ReverseDiff = "37e2e3b7-166d-5795-8a7a-e32c996b4267"
32+
Tracker = "9f7883ad-71c0-57eb-9f7f-b5c9e6d3789c"
33+
Zygote = "e88e6eb3-aa80-5325-afca-941959d7151f"
34+
35+
[[deps.Artifacts]]
36+
uuid = "56f22d72-fd6d-98f1-02f0-08ddc0907c33"
37+
38+
[[deps.Base64]]
39+
uuid = "2a0f44e3-6c83-55bd-87e4-b1978d98bd5f"
40+
41+
[[deps.CompilerSupportLibraries_jll]]
42+
deps = ["Artifacts", "Libdl"]
43+
uuid = "e66e0078-7015-5450-92f7-15fbd957f2ae"
44+
version = "1.0.5+0"
45+
46+
[[deps.Dates]]
47+
deps = ["Printf"]
48+
uuid = "ade2ca70-3891-5945-98fb-dc099432e06a"
49+
50+
[[deps.DocStringExtensions]]
51+
deps = ["LibGit2"]
52+
git-tree-sha1 = "2fb1e02f2b635d0845df5d7c167fec4dd739b00d"
53+
uuid = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae"
54+
version = "0.9.3"
55+
56+
[[deps.Documenter]]
57+
deps = ["ANSIColoredPrinters", "Base64", "Dates", "DocStringExtensions", "IOCapture", "InteractiveUtils", "JSON", "LibGit2", "Logging", "Markdown", "REPL", "Test", "Unicode"]
58+
git-tree-sha1 = "39fd748a73dce4c05a9655475e437170d8fb1b67"
59+
uuid = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
60+
version = "0.27.25"
61+
62+
[[deps.ExprTools]]
63+
git-tree-sha1 = "27415f162e6028e81c72b82ef756bf321213b6ec"
64+
uuid = "e2ba6199-217a-4e67-a87a-7c52f15ade04"
65+
version = "0.1.10"
66+
67+
[[deps.IOCapture]]
68+
deps = ["Logging", "Random"]
69+
git-tree-sha1 = "d75853a0bdbfb1ac815478bacd89cd27b550ace6"
70+
uuid = "b5f81e59-6552-4d32-b1f0-c071b021bf89"
71+
version = "0.2.3"
72+
73+
[[deps.InteractiveUtils]]
74+
deps = ["Markdown"]
75+
uuid = "b77e0a4c-d291-57a0-90e8-8db25a27a240"
76+
77+
[[deps.JSON]]
78+
deps = ["Dates", "Mmap", "Parsers", "Unicode"]
79+
git-tree-sha1 = "31e996f0a15c7b280ba9f76636b3ff9e2ae58c9a"
80+
uuid = "682c06a0-de6a-54ab-a142-c8b1cf79cde6"
81+
version = "0.21.4"
82+
83+
[[deps.LibGit2]]
84+
deps = ["Base64", "NetworkOptions", "Printf", "SHA"]
85+
uuid = "76f85450-5226-5b5a-8eaa-529ad045b433"
86+
87+
[[deps.Libdl]]
88+
uuid = "8f399da3-3557-5675-b5ff-fb832c97cbdb"
89+
90+
[[deps.LinearAlgebra]]
91+
deps = ["Libdl", "OpenBLAS_jll", "libblastrampoline_jll"]
92+
uuid = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
93+
94+
[[deps.Logging]]
95+
uuid = "56ddb016-857b-54e1-b83d-db4d58db5568"
96+
97+
[[deps.Markdown]]
98+
deps = ["Base64"]
99+
uuid = "d6f4376e-aef5-505a-96c1-9c027394607a"
100+
101+
[[deps.Mmap]]
102+
uuid = "a63ad114-7e13-5084-954f-fe012c677804"
103+
104+
[[deps.NetworkOptions]]
105+
uuid = "ca575930-c2e3-43a9-ace4-1e988b2c1908"
106+
version = "1.2.0"
107+
108+
[[deps.OpenBLAS_jll]]
109+
deps = ["Artifacts", "CompilerSupportLibraries_jll", "Libdl"]
110+
uuid = "4536629a-c528-5b80-bd46-f80d51c5b363"
111+
version = "0.3.21+4"
112+
113+
[[deps.Parsers]]
114+
deps = ["Dates", "PrecompileTools", "UUIDs"]
115+
git-tree-sha1 = "716e24b21538abc91f6205fd1d8363f39b442851"
116+
uuid = "69de0a69-1ddd-5017-9359-2bf0b02dc9f0"
117+
version = "2.7.2"
118+
119+
[[deps.PrecompileTools]]
120+
deps = ["Preferences"]
121+
git-tree-sha1 = "9673d39decc5feece56ef3940e5dafba15ba0f81"
122+
uuid = "aea7be01-6a6a-4083-8856-8a6e6704d82a"
123+
version = "1.1.2"
124+
125+
[[deps.Preferences]]
126+
deps = ["TOML"]
127+
git-tree-sha1 = "7eb1686b4f04b82f96ed7a4ea5890a4f0c7a09f1"
128+
uuid = "21216c6a-2e73-6563-6e65-726566657250"
129+
version = "1.4.0"
130+
131+
[[deps.Printf]]
132+
deps = ["Unicode"]
133+
uuid = "de0858da-6303-5e67-8744-51eddeeeb8d7"
134+
135+
[[deps.REPL]]
136+
deps = ["InteractiveUtils", "Markdown", "Sockets", "Unicode"]
137+
uuid = "3fa0cd96-eef1-5676-8a61-b3b8758bbffb"
138+
139+
[[deps.Random]]
140+
deps = ["SHA", "Serialization"]
141+
uuid = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
142+
143+
[[deps.Requires]]
144+
deps = ["UUIDs"]
145+
git-tree-sha1 = "838a3a4188e2ded87a4f9f184b4b0d78a1e91cb7"
146+
uuid = "ae029012-a4dd-5104-9daa-d747884805df"
147+
version = "1.3.0"
148+
149+
[[deps.SHA]]
150+
uuid = "ea8e919c-243c-51af-8825-aaa63cd721ce"
151+
version = "0.7.0"
152+
153+
[[deps.Serialization]]
154+
uuid = "9e88b42a-f829-5b0c-bbe9-9e923198166b"
155+
156+
[[deps.Sockets]]
157+
uuid = "6462fe0b-24de-5631-8697-dd941f90decc"
158+
159+
[[deps.TOML]]
160+
deps = ["Dates"]
161+
uuid = "fa267f1f-6049-4f14-aa54-33bafae1ed76"
162+
version = "1.0.3"
163+
164+
[[deps.Test]]
165+
deps = ["InteractiveUtils", "Logging", "Random", "Serialization"]
166+
uuid = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
167+
168+
[[deps.UUIDs]]
169+
deps = ["Random", "SHA"]
170+
uuid = "cf7118a7-6976-5b1a-9a39-7adc72f591a4"
171+
172+
[[deps.Unicode]]
173+
uuid = "4ec0a83e-493e-50e2-b9ac-8f72acf5a8f5"
174+
175+
[[deps.libblastrampoline_jll]]
176+
deps = ["Artifacts", "Libdl"]
177+
uuid = "8e850b90-86db-534c-a0d3-1478176c7d93"
178+
version = "5.8.0+0"

docs/Project.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[deps]
2+
AbstractDifferentiation = "c29ec348-61ec-40c8-8164-b8c60e9d9f3d"
3+
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"

docs/make.jl

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
using AbstractDifferentiation
2+
using Documenter
3+
4+
DocMeta.setdocmeta!(AbstractDifferentiation, :DocTestSetup, :(using AbstractDifferentiation); recursive=true)
5+
6+
generated_path = joinpath(@__DIR__, "src")
7+
base_url = "https://github.com/JuliaDiff/AbstractDifferentiation.jl/blob/master/"
8+
isdir(generated_path) || mkdir(generated_path)
9+
10+
open(joinpath(generated_path, "index.md"), "w") do io
11+
# Point to source license file
12+
println(
13+
io,
14+
"""
15+
```@meta
16+
EditURL = "$(base_url)README.md"
17+
```
18+
""",
19+
)
20+
# Write the contents out below the meta block
21+
for line in eachline(joinpath(dirname(@__DIR__), "README.md"))
22+
println(io, line)
23+
end
24+
end
25+
26+
makedocs(;
27+
modules=[AbstractDifferentiation],
28+
authors="Mohamed Tarek <mohamed82008@gmail.com> and contributors",
29+
repo="https://github.com/JuliaDiff/AbstractDifferentiation.jl/blob/{commit}{path}#{line}",
30+
sitename="AbstractDifferentiation.jl",
31+
format=Documenter.HTML(;
32+
prettyurls=get(ENV, "CI", "false") == "true",
33+
canonical="https://JuliaDiff.github.io/AbstractDifferentiation.jl",
34+
edit_link="master",
35+
assets=String[],
36+
),
37+
pages=[
38+
"Home" => "index.md",
39+
"API reference" => "api.md",
40+
],
41+
)
42+
43+
deploydocs(;
44+
repo="github.com/JuliaDiff/AbstractDifferentiation.jl",
45+
devbranch="master",
46+
)

docs/src/api.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# API reference
2+
3+
## Index
4+
5+
```@index
6+
```
7+
8+
## Docstrings
9+
10+
```@autodocs
11+
Modules = [AbstractDifferentiation]
12+
```

0 commit comments

Comments
 (0)