grape-starter 0.4.1 → 0.4.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +1 -0
- data/.travis.yml +0 -4
- data/CHANGELOG.md +16 -0
- data/lib/starter/builder.rb +6 -3
- data/lib/starter/version.rb +1 -1
- data/template/api/base.rb +2 -1
- data/template/config.ru +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 567acba57f6b5bbef50e10c04ef3ed959d1d877b
|
4
|
+
data.tar.gz: 68dea7756db9323789392a89435adc899aab2c72
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 50e159bda1bd6411ca34f4ee63269fc6ae403e068e51b64926d29f50d5ba0badbc87d744d5fc1867ffd5fe46a894767d84523e3d6287f2a78a6de794dbbe26ba
|
7
|
+
data.tar.gz: 1065e7cc75744049be7df78c5a2ec275a3786596e37cf6486301bdc3d94b8ff1a4736650bf407f254afc87dabe3d67920b491ed2adcf866e0510b1bf81fbc028
|
data/.rubocop.yml
CHANGED
data/.travis.yml
CHANGED
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,21 @@
|
|
1
1
|
### NEXT
|
2
2
|
|
3
|
+
### 0.4.2
|
4
|
+
|
5
|
+
- sets prefix after project name
|
6
|
+
|
7
|
+
### 0.4.1
|
8
|
+
|
9
|
+
- refactores rack api mounting
|
10
|
+
|
11
|
+
### 0.4.0
|
12
|
+
|
13
|
+
- adds ruby 2.4.0 support
|
14
|
+
|
15
|
+
### 0.3.1
|
16
|
+
|
17
|
+
- server command supports port, thin tag would be named after project
|
18
|
+
|
3
19
|
### 0.3.0
|
4
20
|
|
5
21
|
- adds redoc oapi documentation viewer
|
data/lib/starter/builder.rb
CHANGED
@@ -25,7 +25,10 @@ module Starter
|
|
25
25
|
|
26
26
|
FileUtils.copy_entry source, destination
|
27
27
|
|
28
|
-
replace_static(File.join('script', 'server'))
|
28
|
+
replace_static(File.join('script', 'server'), "API-#{resource}")
|
29
|
+
replace_static(File.join('api', 'base.rb'), ":#{resource}")
|
30
|
+
|
31
|
+
self
|
29
32
|
end
|
30
33
|
|
31
34
|
# would be called from add command
|
@@ -122,10 +125,10 @@ module Starter
|
|
122
125
|
# will be called on project creation
|
123
126
|
#
|
124
127
|
# … static files such as under script folder,
|
125
|
-
def replace_static(file)
|
128
|
+
def replace_static(file, replacement)
|
126
129
|
server_file = File.join(destination, file)
|
127
130
|
|
128
|
-
file_foo(server_file) { |content| content.gsub!('{{{grape-starter}}}',
|
131
|
+
file_foo(server_file) { |content| content.gsub!('{{{grape-starter}}}', replacement) }
|
129
132
|
end
|
130
133
|
|
131
134
|
# will be called an resource creation
|
data/lib/starter/version.rb
CHANGED
data/template/api/base.rb
CHANGED
data/template/config.ru
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: grape-starter
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- LeFnord
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-12-
|
11
|
+
date: 2016-12-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: gli
|