souls 0.61.1 → 0.61.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/souls/cli/db/create_migration_rbs.rb +27 -0
- data/lib/souls/cli/db/index.rb +1 -0
- data/lib/souls/cli/init/index.rb +0 -10
- data/lib/souls/cli/upgrade/index.rb +1 -0
- data/lib/souls/cli/upgrade/submodule.rb +8 -0
- data/lib/souls/cli.rb +1 -1
- data/lib/souls/version.rb +1 -1
- data/lib/souls/versions/.souls_api_version +1 -1
- data/lib/souls/versions/.souls_worker_version +1 -1
- metadata +3 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a395c41a097cf8773d3e19188976b3948e09a9736b157ce351a692ac1c9e5096
|
4
|
+
data.tar.gz: 20617090b1454ca2c6974aee63e4837a6ba31a71111304d745b72d08594e9d4a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6698f7dca334ddae16066fbd55675478fc5c215598ba5c39185e618ffc02929141043f0f1c3b106798426d13deef1f4324736402b3cac0d48e9c3a2522ec18ca
|
7
|
+
data.tar.gz: fc3411de2e75eed68d82897af363e399aeaaf9416e5187e9ff69ba8e754956152410574c2bef3f53e5066112e41d03f9a52c089dee1a18e836859f0ff0e033f6
|
@@ -0,0 +1,27 @@
|
|
1
|
+
module Souls
|
2
|
+
class DB < Thor
|
3
|
+
desc "create_migration_rbs [CLASS_NAME]", "Generate ActiveRecord Migration's RBS Template"
|
4
|
+
def create_migration_rbs(class_name)
|
5
|
+
file_path = ""
|
6
|
+
Dir.chdir(Souls.get_mother_path.to_s) do
|
7
|
+
file_dir = "./sig/api/db/migrate"
|
8
|
+
FileUtils.mkdir_p(file_dir) unless Dir.exist?(file_dir)
|
9
|
+
pluralized_class_name = class_name.underscore.pluralize
|
10
|
+
file_path = "#{file_dir}/create_#{pluralized_class_name}.rbs"
|
11
|
+
File.open(file_path, "w") do |f|
|
12
|
+
f.write(<<~TEXT)
|
13
|
+
class Create#{pluralized_class_name.camelize}
|
14
|
+
def change: () -> untyped
|
15
|
+
def create_table: (:#{pluralized_class_name}) { (untyped) -> untyped } -> untyped
|
16
|
+
def add_index: (:#{pluralized_class_name}, *untyped) -> untyped
|
17
|
+
end
|
18
|
+
TEXT
|
19
|
+
end
|
20
|
+
puts(Paint % ["Created file! : %{white_text}", :green, { white_text: [file_path.to_s, :white] }])
|
21
|
+
end
|
22
|
+
file_path
|
23
|
+
rescue Thor::Error => e
|
24
|
+
raise(Thor::Error, e)
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
data/lib/souls/cli/db/index.rb
CHANGED
data/lib/souls/cli/init/index.rb
CHANGED
@@ -18,16 +18,6 @@ module Souls
|
|
18
18
|
souls_api_credit(app_name: app_name, service_name: service_name)
|
19
19
|
end
|
20
20
|
|
21
|
-
desc "add_submodule", "Run git submodule add RBS collection"
|
22
|
-
def add_submodule
|
23
|
-
system("git submodule add https://github.com/ruby/gem_rbs_collection.git vendor/rbs/gem_rbs_collection")
|
24
|
-
end
|
25
|
-
|
26
|
-
desc "update_submodule", "Run git submodule update --init RBS collection"
|
27
|
-
def update_submodule
|
28
|
-
system("git submodule update --init https://github.com/ruby/gem_rbs_collection.git vendor/rbs/gem_rbs_collection")
|
29
|
-
end
|
30
|
-
|
31
21
|
private
|
32
22
|
|
33
23
|
def get_version(repository_name: "souls_api")
|
data/lib/souls/cli.rb
CHANGED
@@ -22,7 +22,7 @@ module Souls
|
|
22
22
|
desc "sync", " SOULs Sync Commands"
|
23
23
|
subcommand "sync", Sync
|
24
24
|
|
25
|
-
desc "upgrade
|
25
|
+
desc "upgrade [COMMAND]", "SOULs Upgrade Commands"
|
26
26
|
subcommand "upgrade", Upgrade
|
27
27
|
|
28
28
|
# rubocop:disable Style/StringHashKeys
|
data/lib/souls/version.rb
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.40.
|
1
|
+
0.40.2
|
@@ -1 +1 @@
|
|
1
|
-
0.40.
|
1
|
+
0.40.2
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: souls
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.61.
|
4
|
+
version: 0.61.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- POPPIN-FUMI
|
@@ -130,6 +130,7 @@ files:
|
|
130
130
|
- lib/souls/cli.rb
|
131
131
|
- lib/souls/cli/console/index.rb
|
132
132
|
- lib/souls/cli/create/index.rb
|
133
|
+
- lib/souls/cli/db/create_migration_rbs.rb
|
133
134
|
- lib/souls/cli/db/index.rb
|
134
135
|
- lib/souls/cli/docker/index.rb
|
135
136
|
- lib/souls/cli/gcloud/compute/index.rb
|
@@ -188,6 +189,7 @@ files:
|
|
188
189
|
- lib/souls/cli/update/type.rb
|
189
190
|
- lib/souls/cli/upgrade/gemfile.rb
|
190
191
|
- lib/souls/cli/upgrade/index.rb
|
192
|
+
- lib/souls/cli/upgrade/submodule.rb
|
191
193
|
- lib/souls/index.rb
|
192
194
|
- lib/souls/utils/index.rb
|
193
195
|
- lib/souls/version.rb
|