souls 1.18.6 → 1.19.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/souls/app/graphql/types/index.rb +0 -2
- data/lib/souls/cli/create/functions.rb +1 -1
- data/lib/souls/cli/create/templates/go/function.rb +1 -0
- data/lib/souls/cli/create/templates/nodejs/index.rb +1 -0
- data/lib/souls/cli/create/templates/python/main.rb +1 -0
- data/lib/souls/cli/gcloud/functions/index.rb +6 -5
- data/lib/souls/cli/init/index.rb +2 -2
- 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 +2 -4
- data/lib/souls/app/graphql/types/mutation_object.rb +0 -35
- data/lib/souls/app/graphql/types/query_object.rb +0 -18
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1d2f8b89ff6943b75ee7ed2865da9aea86619e56aeaaa75362de4df3787a102d
|
4
|
+
data.tar.gz: bf43499b06e203d0a56425b60fefc81a3b84a21c96e95a116acee05ae43732e0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 072b9e228d261980d705bcf0d14055c3fbaa6cc7176e1574dc1b9574a4e45a2038822d5850e8872766bed9f09dd4d221a341007223756b77e18fdde3675c759a
|
7
|
+
data.tar.gz: 6ace8abce64b7a8537a5d3b9676a1c94149989591ba63332b643aa4d63542d5a012887f32a84e3f8f83cbd62ba84ba325fc95db6bde8b6034548b986c2abe0f8
|
@@ -21,7 +21,7 @@ module SOULs
|
|
21
21
|
version = prompt.select("Select Version?", supported_languages[runtime.downcase.to_sym].sort.reverse)
|
22
22
|
version_string = "#{runtime_downcased}#{version.gsub('.', '')}"
|
23
23
|
runtime_methods = get_runtime_create_method(runtime: runtime_downcased)
|
24
|
-
file_dir = "./apps/
|
24
|
+
file_dir = "./apps/cf-#{version_string}-#{function_name}"
|
25
25
|
FileUtils.mkdir_p(file_dir) unless Dir.exist?(file_dir)
|
26
26
|
|
27
27
|
runtime_methods.each do |method|
|
@@ -5,12 +5,12 @@ module SOULs
|
|
5
5
|
require(SOULs.get_mother_path.to_s + "/config/souls")
|
6
6
|
project_id = SOULs.configuration.project_id
|
7
7
|
current_dir = FileUtils.pwd.split("/").last
|
8
|
-
unless current_dir.match?(/^
|
8
|
+
unless current_dir.match?(/^cf-/)
|
9
9
|
SOULs::Painter.error("You are at wrong dir!\nPlease go to `apps/functions` dir!")
|
10
10
|
return false
|
11
11
|
end
|
12
12
|
|
13
|
-
runtime = current_dir.match(/
|
13
|
+
runtime = current_dir.match(/cf-(\D+\d+)-/)[1]
|
14
14
|
system(
|
15
15
|
"
|
16
16
|
gcloud functions deploy #{current_dir} --project=#{project_id} \
|
@@ -22,11 +22,12 @@ module SOULs
|
|
22
22
|
desc "describe", "Describe SOULs Functions"
|
23
23
|
def describe
|
24
24
|
require(SOULs.get_mother_path.to_s + "/config/souls")
|
25
|
+
current_dir = FileUtils.pwd.split("/").last
|
25
26
|
project_id = SOULs.configuration.project_id
|
26
|
-
system("gcloud functions describe
|
27
|
+
system("gcloud functions describe #{current_dir} --project=#{project_id}")
|
27
28
|
end
|
28
29
|
|
29
|
-
desc "delete", "Delete SOULs Functions"
|
30
|
+
desc "delete [name]", "Delete SOULs Functions"
|
30
31
|
def delete(name)
|
31
32
|
require(SOULs.get_mother_path.to_s + "/config/souls")
|
32
33
|
project_id = SOULs.configuration.project_id
|
@@ -50,7 +51,7 @@ module SOULs
|
|
50
51
|
require(SOULs.get_mother_path.to_s + "/config/souls")
|
51
52
|
project_id = SOULs.configuration.project_id
|
52
53
|
Dir.chdir(SOULs.get_mother_path.to_s) do
|
53
|
-
souls_functions = Dir["apps/
|
54
|
+
souls_functions = Dir["apps/cf-*"]
|
54
55
|
cf_dir = souls_functions.map { |n| n.split("/").last }
|
55
56
|
cf_dir.each do |dir|
|
56
57
|
SOULs::Painter.success(`gcloud functions describe #{dir} --project=#{project_id}| grep url`)
|
data/lib/souls/cli/init/index.rb
CHANGED
@@ -169,7 +169,7 @@ module SOULs
|
|
169
169
|
FileUtils.rm(sig_name)
|
170
170
|
end
|
171
171
|
|
172
|
-
def souls_api_credit(
|
172
|
+
def souls_api_credit(app_name)
|
173
173
|
line = Paint["====================================", :yellow]
|
174
174
|
puts("\n")
|
175
175
|
puts(line)
|
@@ -194,7 +194,7 @@ module SOULs
|
|
194
194
|
puts(line)
|
195
195
|
endroll = <<~TEXT
|
196
196
|
Easy to Run
|
197
|
-
$ cd apps/api
|
197
|
+
$ cd #{app_name}/apps/api
|
198
198
|
$ souls s
|
199
199
|
Go To : http://localhost:4000
|
200
200
|
|
data/lib/souls/version.rb
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.
|
1
|
+
1.19.1
|
@@ -1 +1 @@
|
|
1
|
-
1.
|
1
|
+
1.19.1
|
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: 1.
|
4
|
+
version: 1.19.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- POPPIN-FUMI
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: exe
|
12
12
|
cert_chain: []
|
13
|
-
date: 2022-01-
|
13
|
+
date: 2022-01-06 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: activesupport
|
@@ -167,8 +167,6 @@ files:
|
|
167
167
|
- lib/souls/app/graphql/types/base_scalar.rb
|
168
168
|
- lib/souls/app/graphql/types/base_union.rb
|
169
169
|
- lib/souls/app/graphql/types/index.rb
|
170
|
-
- lib/souls/app/graphql/types/mutation_object.rb
|
171
|
-
- lib/souls/app/graphql/types/query_object.rb
|
172
170
|
- lib/souls/app/index.rb
|
173
171
|
- lib/souls/app/utils/firebase_id_token.rb
|
174
172
|
- lib/souls/app/utils/painter.rb
|
@@ -1,35 +0,0 @@
|
|
1
|
-
module SOULs
|
2
|
-
module Types
|
3
|
-
class MutationObject < SOULs::Types::BaseObject
|
4
|
-
if (FileUtils.pwd.split("/").last != "souls") && File.exist?("./db/schema.rb")
|
5
|
-
get_tables.each do |t|
|
6
|
-
%w[create update delete destroy_delete].each do |a|
|
7
|
-
field "#{a}_#{t.singularize.underscore}".to_sym,
|
8
|
-
mutation: Object.const_get(
|
9
|
-
"Mutations::Base::#{t.singularize.camelize}::#{a.camelize}#{t.singularize.camelize}"
|
10
|
-
)
|
11
|
-
end
|
12
|
-
end
|
13
|
-
managers =
|
14
|
-
Dir["./app/graphql/mutations/managers/*_manager/*.rb"].map do |file|
|
15
|
-
dir_name = file.scan(%r{managers/(.+?)_manager}).flatten[0]
|
16
|
-
file_name = file.scan(%r{/([^/]+)/?$}).flatten[0].gsub(".rb", "")
|
17
|
-
{
|
18
|
-
class: dir_name,
|
19
|
-
name: file_name
|
20
|
-
}
|
21
|
-
end
|
22
|
-
managers.each do |file|
|
23
|
-
field file[:name].underscore.to_s.to_sym,
|
24
|
-
mutation: Object.const_get(
|
25
|
-
"Mutations::Managers::#{
|
26
|
-
file[:class].singularize.camelize
|
27
|
-
}Manager::#{
|
28
|
-
file[:name].singularize.camelize
|
29
|
-
}"
|
30
|
-
)
|
31
|
-
end
|
32
|
-
end
|
33
|
-
end
|
34
|
-
end
|
35
|
-
end
|
@@ -1,18 +0,0 @@
|
|
1
|
-
module SOULs
|
2
|
-
module Types
|
3
|
-
class QueryObject < SOULs::Types::BaseObject
|
4
|
-
if (FileUtils.pwd.split("/").last != "souls") && File.exist?("./db/schema.rb")
|
5
|
-
add_field(GraphQL::Types::Relay::NodeField)
|
6
|
-
add_field(GraphQL::Types::Relay::NodesField)
|
7
|
-
get_tables.each do |t|
|
8
|
-
field t.singularize.underscore.to_s.to_sym, resolver: Object.const_get("Queries::#{t.singularize.camelize}")
|
9
|
-
field "#{t.singularize.underscore}_search".to_sym,
|
10
|
-
resolver: Object.const_get("Resolvers::#{t.singularize.camelize}Search")
|
11
|
-
field t.pluralize.underscore.to_s.to_sym,
|
12
|
-
Object.const_get("Types::#{t.singularize.camelize}Type").connection_type,
|
13
|
-
null: true
|
14
|
-
end
|
15
|
-
end
|
16
|
-
end
|
17
|
-
end
|
18
|
-
end
|