|  | 
| 1 | 1 | using Documenter | 
| 2 | 2 | using GraphNeuralNetworks | 
|  | 3 | +using Flux, GNNGraphs, GNNlib, Graphs, NNlib | 
|  | 4 | +# using GNNGraphs, GNNlib # no need to load since they are re-exported by GraphNeuralNetworks | 
| 3 | 5 | using DocumenterInterLinks | 
| 4 | 6 | 
 | 
|  | 7 | +DocMeta.setdocmeta!(GraphNeuralNetworks, :DocTestSetup, :(using GraphNeuralNetworks); recursive = true) | 
|  | 8 | + | 
|  | 9 | +mathengine = MathJax3(Dict(:loader => Dict("load" => ["[tex]/require", "[tex]/mathtools"]), | 
|  | 10 | +    :tex => Dict("inlineMath" => [["\$", "\$"], ["\\(", "\\)"]], | 
|  | 11 | +        "packages" => [ | 
|  | 12 | +            "base", | 
|  | 13 | +            "ams", | 
|  | 14 | +            "autoload", | 
|  | 15 | +            "mathtools", | 
|  | 16 | +            "require" | 
|  | 17 | +        ]))) | 
| 5 | 18 | 
 | 
| 6 |  | -assets=[] | 
| 7 |  | -prettyurls = get(ENV, "CI", nothing) == "true" | 
| 8 |  | -mathengine = MathJax3() | 
| 9 | 19 | 
 | 
| 10 | 20 | interlinks = InterLinks( | 
| 11 | 21 |     "NNlib" => "https://fluxml.ai/NNlib.jl/stable/", | 
| 12 |  | -    "GNNGraphs" => ("https://carlolucibello.github.io/GraphNeuralNetworks.jl/GNNGraphs/",  joinpath(dirname(dirname(@__DIR__)), "GNNGraphs", "docs", "build", "objects.inv")), | 
| 13 |  | -    "GNNlib" => ("https://carlolucibello.github.io/GraphNeuralNetworks.jl/GNNlib/",  joinpath(dirname(dirname(@__DIR__)), "GNNlib", "docs", "build", "objects.inv")) | 
| 14 |  | -    | 
|  | 22 | +    # "GNNGraphs" => ("https://carlolucibello.github.io/GraphNeuralNetworks.jl/GNNGraphs/",  joinpath(dirname(dirname(@__DIR__)), "GNNGraphs", "docs", "build", "objects.inv")), | 
|  | 23 | +    # "GNNlib" => ("https://carlolucibello.github.io/GraphNeuralNetworks.jl/GNNlib/",  joinpath(dirname(dirname(@__DIR__)), "GNNlib", "docs", "build", "objects.inv")) | 
| 15 | 24 |    ) | 
| 16 | 25 | 
 | 
| 17 |  | -# Copy the guides from GNNGraphs and GNNlib | 
| 18 |  | -dest_guides_dir = joinpath(@__DIR__, "src/other") | 
| 19 |  | -gnngraphs_guides_dir = joinpath(@__DIR__, "../../GNNGraphs/docs/src/guides") | 
| 20 |  | -gnnlib_guides_dir = joinpath(@__DIR__, "../../GNNlib/docs/src/guides")  | 
| 21 |  | -for file in readdir(gnngraphs_guides_dir) | 
| 22 |  | -    cp(joinpath(gnngraphs_guides_dir, file), joinpath(dest_guides_dir, file), force=true) | 
| 23 |  | -end | 
| 24 |  | -for file in readdir(gnnlib_guides_dir) | 
| 25 |  | -    cp(joinpath(gnnlib_guides_dir, file), joinpath(dest_guides_dir, file), force=true) | 
| 26 |  | -end | 
|  | 26 | +# Copy the docs from GNNGraphs and GNNlib. Will be removed at the end of the script | 
|  | 27 | +cp(joinpath(@__DIR__, "../../GNNGraphs/docs/src"), | 
|  | 28 | +   joinpath(@__DIR__, "src/GNNGraphs"), force=true) | 
|  | 29 | +cp(joinpath(@__DIR__, "../../GNNlib/docs/src"), | 
|  | 30 | +   joinpath(@__DIR__, "src/GNNlib"), force=true) | 
| 27 | 31 | 
 | 
| 28 | 32 | makedocs(; | 
| 29 |  | -    modules = [GraphNeuralNetworks], | 
|  | 33 | +    modules = [GraphNeuralNetworks, GNNGraphs, GNNlib], | 
| 30 | 34 |     doctest = false, # TODO: enable doctest | 
| 31 |  | -    clean = true, | 
| 32 | 35 |     plugins = [interlinks], | 
| 33 |  | -    format = Documenter.HTML(; mathengine, prettyurls, assets = assets, size_threshold=nothing), | 
|  | 36 | +    format = Documenter.HTML(; mathengine,  | 
|  | 37 | +                            prettyurls = get(ENV, "CI", nothing) == "true",  | 
|  | 38 | +                            assets = [], | 
|  | 39 | +                            size_threshold=nothing,  | 
|  | 40 | +                            size_threshold_warn=200000), | 
| 34 | 41 |     sitename = "GraphNeuralNetworks.jl", | 
| 35 | 42 |     pages = [ | 
| 36 | 43 | 
 | 
| 37 | 44 |     "Home" => "index.md", | 
| 38 | 45 | 
 | 
| 39 | 46 |     "Guides" => [ | 
| 40 |  | -        "Graphs" => ["other/gnngraph.md", "other/heterograph.md", "other/temporalgraph.md"], | 
| 41 |  | -        "Message Passing" => "other/messagepassing.md", | 
|  | 47 | +        "Graphs" => ["GNNGraphs/guides/gnngraph.md",  | 
|  | 48 | +                    "GNNGraphs/guides/heterograph.md",  | 
|  | 49 | +                    "GNNGraphs/guides/temporalgraph.md"], | 
|  | 50 | +        "Message Passing" => "GNNlib/guides/messagepassing.md", | 
| 42 | 51 |         "Models" => "guides/models.md", | 
| 43 |  | -        "Datasets" => "other/datasets.md", | 
|  | 52 | +        "Datasets" => "GNNGraphs/guides/datasets.md", | 
| 44 | 53 |     ], | 
| 45 | 54 | 
 | 
| 46 | 55 |     "API Reference" => [ | 
|  | 56 | +            "Message Passing" => "GNNlib/api/messagepassing.md", | 
|  | 57 | +            "Utils" => "GNNlib/api/utils.md", | 
| 47 | 58 |             "Basic" => "api/basic.md", | 
| 48 | 59 |             "Convolutional layers" => "api/conv.md", | 
| 49 | 60 |             "Pooling layers" => "api/pool.md", | 
| 50 | 61 |             "Temporal Convolutional layers" => "api/temporalconv.md", | 
| 51 | 62 |             "Hetero Convolutional layers" => "api/heteroconv.md", | 
|  | 63 | + | 
| 52 | 64 |         ], | 
| 53 |  | -        "Developer guide" => "dev.md", | 
|  | 65 | +     | 
|  | 66 | +    "Developer guide" => "dev.md", | 
| 54 | 67 |     ], | 
| 55 | 68 | ) | 
| 56 |  | -          | 
| 57 |  | -deploydocs(;repo = "github.com/JuliaGraphs/GraphNeuralNetworks.jl.git", devbranch = "master", dirname= "GraphNeuralNetworks") | 
|  | 69 | + | 
|  | 70 | +rm(joinpath(@__DIR__, "src/GNNGraphs"), force=true, recursive=true) | 
|  | 71 | +rm(joinpath(@__DIR__, "src/GNNlib"), force=true, recursive=true) | 
|  | 72 | + | 
|  | 73 | +deploydocs(repo = "github.com/JuliaGraphs/GraphNeuralNetworks.jl.git",  | 
|  | 74 | +          devbranch = "master",  | 
|  | 75 | +          dirname= "GraphNeuralNetworks") | 
0 commit comments