Skip to content

Commit 0ea237f

Browse files
authored
Write the structure.png file to the correct location
1 parent 06f3302 commit 0ea237f

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

bin/structure.jl

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
using LightGraphs, PkgAuthentication, GraphPlot, Cairo, Compose
22

3-
file = joinpath(dirname(@__DIR__), "src", "PkgAuthentication.jl")
3+
const bin_dir = @__DIR__
4+
const root_dir = dirname(bin_dir)
5+
const src_dir = joinpath(root_dir, "src")
6+
const docs_dir = joinpath(root_dir, "docs")
7+
const docs_assets_dir = joinpath(docs_dir, "assets")
8+
9+
file = joinpath(src_dir, "PkgAuthentication.jl")
410

511
g = SimpleDiGraph()
612
lines = readlines(file)
@@ -19,4 +25,4 @@ for line in lines
1925
end
2026
end
2127
plot = gplot(g, nodelabel=vertices, linetype="curve")
22-
draw(PNG(joinpath(@__DIR__, "structure.png"), 16cm, 16cm), plot)
28+
draw(PNG(joinpath(docs_assets_dir, "structure.png"), 16cm, 16cm), plot)

0 commit comments

Comments
 (0)