jekyll-structurizr 0.0.1 → 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/jekyll-structurizr.rb +17 -12
- data/lib/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4dc24c99c381c7be577cf824559f4d2e27ba17c715b92f96610dde26069dcc34
|
4
|
+
data.tar.gz: 073f704ee041c6fcb933587c61964b760a31256e8adea9bffb75740f6ee31509
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d0ba7e26ceb21bd155c59be6fe75b218c5dbf48ef7f629d5064c590dc4c5b9b62c68d6eb7827b10ae4f17ddd7216aa53788e757505a44af12e649b2d99399546
|
7
|
+
data.tar.gz: '099715cd183820117962bb5ffec160e05c086afc9ab7041c423ee64de56fa308f970117ccc0f3c7dd990b1be67deb31c3391266cc1392c2981bbadfbb1db2f16'
|
data/lib/jekyll-structurizr.rb
CHANGED
@@ -12,7 +12,9 @@ module Jekyll
|
|
12
12
|
site = context.registers[:site]
|
13
13
|
name = Digest::MD5.hexdigest(super)
|
14
14
|
if !File.exists?(File.join(site.dest, "c4/#{name}.svg"))
|
15
|
+
outputdir = File.join(site.source, "c4")
|
15
16
|
dsl = File.join(site.source, "c4/#{name}.dsl")
|
17
|
+
defaultuml = File.join(site.source, "c4/structurizr-SystemContext.puml")
|
16
18
|
uml = File.join(site.source, "c4/#{name}.uml")
|
17
19
|
svg = File.join(site.source, "c4/#{name}.svg")
|
18
20
|
if File.exists?(svg)
|
@@ -21,21 +23,24 @@ module Jekyll
|
|
21
23
|
FileUtils.mkdir_p(File.dirname(dsl))
|
22
24
|
File.open(dsl, 'w') { |f|
|
23
25
|
@text = super
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
26
|
+
# appendC4Beacon=true
|
27
|
+
# if @text.include? "@starstructurizr"
|
28
|
+
# appendC4Beacon = false
|
29
|
+
# puts "stream already contains starstructurizr beacons"
|
30
|
+
# end
|
31
|
+
# if appendC4Beacon
|
32
|
+
# f.write("@starstructurizr\n")
|
33
|
+
# end
|
32
34
|
f.write(super)
|
33
|
-
|
34
|
-
|
35
|
-
|
35
|
+
# if appendC4Beacon
|
36
|
+
# f.write("\n@endstructurizr")
|
37
|
+
# end
|
36
38
|
}
|
37
|
-
|
39
|
+
puts "Exec : structurizr export -f plantuml/c4plantuml -o #{outputdir} -w #{dsl}"
|
40
|
+
system("structurizr export -f plantuml/structurizr -o #{outputdir} -w #{dsl}")
|
41
|
+
File.rename(defaultuml, uml)
|
38
42
|
puts "File #{uml} created (#{File.size(uml)} bytes)"
|
43
|
+
puts "plantuml -tsvg #{uml}"
|
39
44
|
system("plantuml -tsvg #{uml}")
|
40
45
|
site.static_files << Jekyll::StaticFile.new(
|
41
46
|
site, site.source, 'c4', "#{name}.svg"
|
data/lib/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jekyll-structurizr
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0
|
4
|
+
version: 0.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sebastien Andreo
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-04-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: jekyll
|