Diagrame daj v svoje datoteke
This commit is contained in:
parent
0e6a68fb0a
commit
b6c83ca3e5
8 changed files with 140 additions and 111 deletions
21
diagrams/branch-move.typ
Normal file
21
diagrams/branch-move.typ
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
#import "@preview/fletcher:0.5.8" as fletcher: diagram, node, edge
|
||||
#import fletcher.shapes: house, chevron, pill
|
||||
#import "../definicije.typ": file-object, tree-object, git-object, commit-object
|
||||
|
||||
#diagram(node-stroke: 0.5pt,
|
||||
{
|
||||
node((1, -1), [main], shape: chevron, name: <main-old>, stroke:(dash: "dotted"))
|
||||
node((-1, 0), [`e23d19`], shape: pill, name: <commit1>)
|
||||
node((0, 0), [`3943eb`], shape: pill, name: <commit2>)
|
||||
node((1, 0), [`98ff21`], shape: pill, name: <commit3>)
|
||||
node((2, 0), [`4e96a1`], shape: pill, name: <commit4>, stroke: blue)
|
||||
node((2, -1), [main], shape: chevron, name: <main>)
|
||||
node((1, 1), [v-1.0], shape: chevron, name: <tag>)
|
||||
edge(<commit2>, <commit1>, "->")
|
||||
edge(<commit3>, <commit2>, "->")
|
||||
edge(<commit4>, <commit3>, "->", stroke: blue)
|
||||
edge(<main-old>, <commit3>, "->", stroke: (dash: "dotted"))
|
||||
edge(<tag>, <commit3>, "->")
|
||||
edge(<main>, <commit4>, "->")
|
||||
}
|
||||
)
|
||||
19
diagrams/branches-tags.typ
Normal file
19
diagrams/branches-tags.typ
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
#import "@preview/fletcher:0.5.8" as fletcher: diagram, node, edge
|
||||
#import fletcher.shapes: house, chevron, pill
|
||||
#import "../definicije.typ": file-object, tree-object, git-object, commit-object
|
||||
|
||||
#diagram(node-stroke: 0.5pt,
|
||||
{
|
||||
node((2, -1), [main], shape: chevron, name: <main>)
|
||||
node((-1, 0), [`e23d19`], shape: pill, name: <commit1>)
|
||||
node((0, 0), [`3943eb`], shape: pill, name: <commit2>)
|
||||
node((1, 0), [`98ff21`], shape: pill, name: <commit3>)
|
||||
node((2, 0), [`4e96a1`], shape: pill, name: <commit4>)
|
||||
node((0, 1), [v-1.0], shape: chevron.with(dir: left), name: <tag>)
|
||||
edge(<commit2>, <commit1>, "->")
|
||||
edge(<commit3>, <commit2>, "->")
|
||||
edge(<commit4>, <commit3>, "->")
|
||||
edge(<main>, <commit4>, "->")
|
||||
edge(<tag>, <commit2>, "->")
|
||||
}
|
||||
)
|
||||
24
diagrams/commit-history.typ
Normal file
24
diagrams/commit-history.typ
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
#import "@preview/fletcher:0.5.8" as fletcher: diagram, node, edge
|
||||
#import fletcher.shapes: house, chevron, pill
|
||||
#import "../definicije.typ": file-object, tree-object, git-object, commit-object
|
||||
|
||||
#diagram(node-stroke: 1pt, node-shape: pill,
|
||||
{
|
||||
let (Ah, Bh, Ch, Dh, Eh, Fh, Gh) = ("d93434", "2ca420", "dd0d98", "28782c", "710310", "3f2922","d2a671")
|
||||
let (A, B, C, D, E, F, G) = ((0, 0), (1, 0), (2, 0), (3, 0), (4, 0), (2, 1), (3, 1))
|
||||
node(A, raw(Ah))
|
||||
node(B, raw(Bh))
|
||||
node(C, raw(Ch))
|
||||
node(D, raw(Dh))
|
||||
node(E, raw(Eh))
|
||||
node(F, raw(Fh))
|
||||
node(G, raw(Gh))
|
||||
edge(B, A, "->")
|
||||
edge(C, B, "->")
|
||||
edge(D, C, "->")
|
||||
edge(E, D, "->")
|
||||
edge(G, F, "->")
|
||||
edge(F, B, "->")
|
||||
edge(D, F, "->")
|
||||
}
|
||||
)
|
||||
16
diagrams/file-graph.typ
Normal file
16
diagrams/file-graph.typ
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
#import "@preview/fletcher:0.5.8" as fletcher: diagram, node, edge
|
||||
#import fletcher.shapes: house, chevron, pill
|
||||
#import "../definicije.typ": file-object, tree-object, git-object, commit-object, bla, blabla
|
||||
|
||||
#diagram(
|
||||
{
|
||||
bla((-1, 1), name:<bla>)
|
||||
blabla((-1, 0), name: <blabla>)
|
||||
tree-object((1, 1), "ae247f", name: <mapa>)[drevo]
|
||||
tree-object((3, 0), "473e0b", name: <root>)[drevo]
|
||||
edge(<root>, <bla>, "->", label-angle: auto)[`bla.txt`]
|
||||
edge(<root>, <mapa>, "->", label-angle: auto, label-sep: -1.2em)[`mapa`]
|
||||
edge(<mapa>, <bla>, "->", label-angle: auto, label-sep: -1.2em)[`bla.txt`]
|
||||
edge(<root>, <blabla>, "->")[`blabla.txt`]
|
||||
}
|
||||
)
|
||||
22
diagrams/head-index.typ
Normal file
22
diagrams/head-index.typ
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
#import "@preview/fletcher:0.5.8" as fletcher: diagram, node, edge
|
||||
#import fletcher.shapes: house, chevron, pill
|
||||
#import "../definicije.typ": file-object, tree-object, git-object, commit-object
|
||||
|
||||
#diagram(node-stroke: 0.5pt,
|
||||
{
|
||||
node((-1, 0), [`e23d19`], shape: pill, name: <commit1>)
|
||||
node((0, 0), [`3943eb`], shape: pill, name: <commit2>)
|
||||
node((1, 0), [`98ff21`], shape: pill, name: <commit3>)
|
||||
node((2, 0), [`4e96a1`], shape: pill, name: <commit4>, stroke: (dash: "dotted"))
|
||||
node((1, -1), [main], shape: chevron, name: <main>)
|
||||
node((1, 1), [HEAD], shape: chevron, name: <head>)
|
||||
node((2, 1), [index], shape: rect, name: <index>, stroke: (dash: "dotted"))
|
||||
|
||||
edge(<commit2>, <commit1>, "->")
|
||||
edge(<commit3>, <commit2>, "->")
|
||||
edge(<commit4>, <commit3>, "->", stroke: (dash: "dotted"))
|
||||
edge(<index>, <commit4>, "->", stroke: (dash: "dotted"))
|
||||
edge(<head>, <commit3>, "->")
|
||||
edge(<main>, <commit3>, "->")
|
||||
}
|
||||
)
|
||||
26
diagrams/object-storage.typ
Normal file
26
diagrams/object-storage.typ
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
#import "@preview/fletcher:0.5.8" as fletcher: diagram, node, edge
|
||||
#import fletcher.shapes: house, chevron, pill
|
||||
#import "../definicije.typ": file-object, tree-object, git-object, commit-object, bla, blabla
|
||||
|
||||
#diagram(
|
||||
{
|
||||
node((0, -1))[vsebina (blob)]
|
||||
node((2, -1))[drevesa (tree)]
|
||||
node((4, -1))[vnosi (commit)]
|
||||
bla((0, -0.5), name:<bla>)
|
||||
blabla((0, 0.5), name:<blabla>)
|
||||
file-object((0, 1.5),"33476f", name:<bla1>)[bla!]
|
||||
tree-object((2, 0), "5e12fg", name:<koren0>)[koren]
|
||||
tree-object((2, 1), "32e4f1", name: <koren1>)[koren]
|
||||
commit-object((4, 0), "7e43a1", name: <commit0>)[Prvi vnos]
|
||||
commit-object((4, 1), "4ef531", name: <commit1>)[Popravi bla.txt]
|
||||
edge(<commit0>, <koren0>, "->")
|
||||
edge(<commit1>, <koren1>, "->")
|
||||
edge(<commit1>, <commit0>, "->")[starš]
|
||||
edge(<koren0>, <bla>, "->")[bla.txt]
|
||||
edge(<koren1>, <bla1>, "->", label-angle: auto)[bla.txt]
|
||||
edge(<koren0>, <blabla>, "->", label-angle: auto)[blabla.txt]
|
||||
edge(<koren1>, <blabla>, "->", label-angle: auto)[blabla.txt]
|
||||
edge(<commit0>, <koren0>, "->")
|
||||
}
|
||||
)
|
||||
Loading…
Add table
Add a link
Reference in a new issue