ruby_uml_class 0.2.0 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: cbb2258a4f230b1d76894dd6507c1dd07d3df5fff834108715f7864b8c0ff9a3
4
- data.tar.gz: 39892397797367876a4159b152c346ae7878a88075973564a451b8ba9de4997b
3
+ metadata.gz: 40485ad2bf0d6ef8448bfe03b372e4fb00a6d0d0aa2cb2ba7787f49f9e9afd6c
4
+ data.tar.gz: 2b7b8230ae33d90d0cb2aa3f53dffd7098c75cbdd598454d621cd0a1c365c7c2
5
5
  SHA512:
6
- metadata.gz: c6f84a2e2e3f26dcb53d62d2fd841420c1d1162f066dac3d5b5946c4ca82cd749c3b9182ba08374a6cbe668fa346ec12d402d022a032f9689d0d20fc9bd3a23c
7
- data.tar.gz: cae6b70c56567d1e6234439a5ab76852b60c4c15fc8a2974fe7de6329cd1bbef51c06636cd60e93dc1ca51540f0d1beb17c3f0a64aaa52bf901e84daacc187d8
6
+ metadata.gz: ae957e7b5178b1919cf06314170ef260f25d152cd9dd50f97ba471846d425a5db3a38de57f6900e7016bb3c7b57cdbbd97d6da1a1a83035f70905224e26b18ce
7
+ data.tar.gz: 4ec479ab9f6eab276e04aabec05d2e9b0903982a2e9cd99305e16cd8dc43b5d4f38e65542768b4a98363e69b125ffac65bc40f801a41d5b2c8a4cec4144bce6f
data/README.md CHANGED
@@ -1,37 +1,45 @@
1
- # RubyUmlClass
2
-
3
- RubyUmlClass creates a Ruby class diagram.
4
- PlantUML and rufo commands are used to create class diagrams.
5
- The created class diagram is displayed on the browser screen.
6
-
7
- ## Setup
8
- for ubuntu
9
- $ sudo apt install plantuml
10
-
11
- ## Installation
12
-
13
- Install the gem and add to the application's Gemfile by executing:
14
-
15
- $ bundle add ruby_uml_class
16
-
17
- If bundler is not being used to manage dependencies, install the gem by executing:
18
-
19
- $ gem install ruby_uml_class
20
-
21
- ## Usage
22
-
23
- $ start_ruby_uml_class.rb
24
-
25
- https://user-images.githubusercontent.com/88954426/211500980-3bb839a9-8cf5-44da-b8f9-733a87f22c96.mp4
26
-
27
- ## Development
28
-
29
- To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).
30
-
31
- ## Contributing
32
-
33
- Bug reports and pull requests are welcome on GitHub at https://github.com/kuwayama1971/RubyUmlClass.
34
-
35
- ## License
36
-
37
- The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
1
+ # RubyUmlClass
2
+
3
+ RubyUmlClass creates a Ruby class diagram.
4
+ PlantUML and rufo commands are used to create class diagrams.
5
+ The created class diagram is displayed on the browser screen.
6
+
7
+ ## Setup
8
+ for ubuntu
9
+ $ sudo apt install plantuml
10
+
11
+ for windoes
12
+ install java and PlanUML
13
+ Set java and plantuml.jar in [PlantUML Command]
14
+ PlantUML of vscode extension function is also possible
15
+
16
+ Set [RubyUmlClass=>Setting=>PlantUML Command] as follows
17
+ "java -jar C:/Users/%USERNAME%/.vscode/extensions/jebbs.plantuml-2.17.5/plantuml.jar -svg --charset UTF-8"
18
+
19
+ ## Installation
20
+
21
+ Install the gem and add to the application's Gemfile by executing:
22
+
23
+ $ bundle add ruby_uml_class
24
+
25
+ If bundler is not being used to manage dependencies, install the gem by executing:
26
+
27
+ $ gem install ruby_uml_class
28
+
29
+ ## Usage
30
+
31
+ $ start_ruby_uml_class.rb
32
+
33
+ https://user-images.githubusercontent.com/88954426/211500980-3bb839a9-8cf5-44da-b8f9-733a87f22c96.mp4
34
+
35
+ ## Development
36
+
37
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).
38
+
39
+ ## Contributing
40
+
41
+ Bug reports and pull requests are welcome on GitHub at https://github.com/kuwayama1971/RubyUmlClass.
42
+
43
+ ## License
44
+
45
+ The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
File without changes
File without changes
@@ -1,19 +1,19 @@
1
- {
2
- "version": 0.1,
3
- "setting_list": [
4
- {
5
- "name": "plantuml",
6
- "value": "plantuml -svg --charset UTF-8",
7
- "type": "input",
8
- "select": "",
9
- "description": "PlantUMLコマンド"
10
- },
11
- {
12
- "name": "editor",
13
- "value": "code",
14
- "type": "input",
15
- "select": "",
16
- "description": "UMLを開くエディタ"
17
- }
18
- ]
19
- }
1
+ {
2
+ "version": 0.1,
3
+ "setting_list": [
4
+ {
5
+ "name": "plantuml",
6
+ "value": "plantuml -svg --charset UTF-8",
7
+ "type": "input",
8
+ "select": "",
9
+ "description": "PlantUMLコマンド"
10
+ },
11
+ {
12
+ "name": "editor",
13
+ "value": "code",
14
+ "type": "input",
15
+ "select": "",
16
+ "description": "UMLを開くエディタ"
17
+ }
18
+ ]
19
+ }
data/lib/config.ru CHANGED
@@ -1,107 +1,107 @@
1
- # -*- coding: utf-8 -*-
2
- require "sinatra"
3
- require "sinatra/contrib"
4
- require "sinatra-websocket"
5
- require "thin"
6
- require "json"
7
-
8
- require "./server"
9
- require "./wsserver"
10
-
11
- access_log = File.new("#{$home_dir}/logs/sinatra.log", "a+")
12
- access_log.sync = true
13
- use Rack::CommonLogger, access_log
14
-
15
- get "/" do
16
- File.read("html/index.html")
17
- end
18
-
19
- get "*.html" do |file|
20
- content_type "text/html", :charset => "utf-8"
21
- File.read "./html/#{file}.html"
22
- end
23
-
24
- get "/css/:name.css" do
25
- content_type "text/css", :charset => "utf-8"
26
- puts "css/#{params[:name]}.css"
27
- File.read "css/#{params[:name]}.css"
28
- end
29
-
30
- get "/js/:name.js" do
31
- content_type "text/javascript", :charset => "utf-8"
32
- puts "js/#{params[:name]}.js"
33
- File.read "js/#{params[:name]}.js"
34
- end
35
-
36
- get "/config/*.*" do |file, ext|
37
- content_type "text/json", :charset => "utf-8"
38
- puts "#{file}.#{ext}"
39
- File.read "#{$home_dir}/config/#{file}.#{ext}"
40
- end
41
-
42
- post "/history/*.*" do |file, ext|
43
- content_type "text/json", :charset => "utf-8"
44
- puts "#{file}.#{ext}"
45
- p = params[:param1]
46
- begin
47
- buf = File.read "#{$home_dir}/history/#{file}.#{ext}"
48
- rescue
49
- buf = ""
50
- end
51
- data = eval(buf)
52
- if data != nil
53
- if p != ""
54
- JSON.generate data.find_all { |d| d =~ Regexp.new(p) }
55
- else
56
- JSON.generate data
57
- end
58
- end
59
- end
60
-
61
- get "/open_dialog" do
62
- dialog_html = <<'EOS'
63
- <!DOCTYPE html>
64
- <html>
65
- <head>
66
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
67
- <title>Message Dialog</title>
68
- <style type="text/css">
69
- <!--
70
- body {
71
- color: #000000;
72
- background-color: #ffffff;
73
- overflow: hidden;
74
- font-size: 12px;
75
- }
76
- -->
77
- </style>
78
- </head>
79
- EOS
80
- dialog_html += "<body>" + params["msg"] + "</body></html>"
81
- end
82
-
83
- map "/search" do
84
- run Search
85
- end
86
-
87
- map "/wsserver" do
88
- res = catch(:halt) do
89
- run WsServer
90
- end
91
- puts res
92
- end
93
-
94
- configure do
95
- set :DoNotReverseLookup, true
96
- set :logging, true
97
- set :default_encoding, "utf-8"
98
- set :server, :thin
99
-
100
- # Thread.start {
101
- # }
102
-
103
- end
104
-
105
- #\ --port 35983
106
-
107
- run Sinatra::Application
1
+ # -*- coding: utf-8 -*-
2
+ require "sinatra"
3
+ require "sinatra/contrib"
4
+ require "sinatra-websocket"
5
+ require "thin"
6
+ require "json"
7
+
8
+ require "./server"
9
+ require "./wsserver"
10
+
11
+ access_log = File.new("#{$home_dir}/logs/sinatra.log", "a+")
12
+ access_log.sync = true
13
+ use Rack::CommonLogger, access_log
14
+
15
+ get "/" do
16
+ File.read("html/index.html")
17
+ end
18
+
19
+ get "*.html" do |file|
20
+ content_type "text/html", :charset => "utf-8"
21
+ File.read "./html/#{file}.html"
22
+ end
23
+
24
+ get "/css/:name.css" do
25
+ content_type "text/css", :charset => "utf-8"
26
+ puts "css/#{params[:name]}.css"
27
+ File.read "css/#{params[:name]}.css"
28
+ end
29
+
30
+ get "/js/:name.js" do
31
+ content_type "text/javascript", :charset => "utf-8"
32
+ puts "js/#{params[:name]}.js"
33
+ File.read "js/#{params[:name]}.js"
34
+ end
35
+
36
+ get "/config/*.*" do |file, ext|
37
+ content_type "text/json", :charset => "utf-8"
38
+ puts "#{file}.#{ext}"
39
+ File.read "#{$home_dir}/config/#{file}.#{ext}"
40
+ end
41
+
42
+ post "/history/*.*" do |file, ext|
43
+ content_type "text/json", :charset => "utf-8"
44
+ puts "#{file}.#{ext}"
45
+ p = params[:param1]
46
+ begin
47
+ buf = File.read "#{$home_dir}/history/#{file}.#{ext}"
48
+ rescue
49
+ buf = ""
50
+ end
51
+ data = eval(buf)
52
+ if data != nil
53
+ if p != ""
54
+ JSON.generate data.find_all { |d| d =~ Regexp.new(p) }
55
+ else
56
+ JSON.generate data
57
+ end
58
+ end
59
+ end
60
+
61
+ get "/open_dialog" do
62
+ dialog_html = <<'EOS'
63
+ <!DOCTYPE html>
64
+ <html>
65
+ <head>
66
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
67
+ <title>Message Dialog</title>
68
+ <style type="text/css">
69
+ <!--
70
+ body {
71
+ color: #000000;
72
+ background-color: #ffffff;
73
+ overflow: hidden;
74
+ font-size: 12px;
75
+ }
76
+ -->
77
+ </style>
78
+ </head>
79
+ EOS
80
+ dialog_html += "<body>" + params["msg"] + "</body></html>"
81
+ end
82
+
83
+ map "/search" do
84
+ run Search
85
+ end
86
+
87
+ map "/wsserver" do
88
+ res = catch(:halt) do
89
+ run WsServer
90
+ end
91
+ puts res
92
+ end
93
+
94
+ configure do
95
+ set :DoNotReverseLookup, true
96
+ set :logging, true
97
+ set :default_encoding, "utf-8"
98
+ set :server, :thin
99
+
100
+ # Thread.start {
101
+ # }
102
+
103
+ end
104
+
105
+ #\ --port 35983
106
+
107
+ run Sinatra::Application