gamefic-sdk 3.2.0 → 3.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/gamefic-sdk/tasks/web.rb +2 -2
- data/lib/gamefic-sdk/tasks.rb +3 -4
- data/lib/gamefic-sdk/version.rb +1 -1
- data/scaffolds/project/Rakefile.gf.erb +2 -2
- 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: bfae698c7fc6e90d559be158ad0b86b2a2c5066ff6837465347634849d7804c8
|
4
|
+
data.tar.gz: 05fb55ff00ca7f25c43c11676732272a84b048f1add4160a3ac58366f9bd48a7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: '02483f530bf30a9b98acb9fe90b77172b075cc8928cfe1d7e016b35d600bbd49bbbe79f20bdf7487e949808be3242672d07cf7ca105f28a3ad8c97f0cd1ed1a7'
|
7
|
+
data.tar.gz: 0bda3d0de120dba333ba0800de784cfe0e2c267427e42203f93ef3ab18feb9ca6f09e4cd03e02d7c87334a59f20c4974966b928132122791f00ffaabcce3b5f1
|
data/CHANGELOG.md
CHANGED
@@ -12,13 +12,13 @@ module Gamefic
|
|
12
12
|
|
13
13
|
# Generate a web app using NPM.
|
14
14
|
#
|
15
|
-
def generate
|
15
|
+
def generate version = '@latest'
|
16
16
|
puts "Node version #{check_for_npm} detected. Preparing the web app..."
|
17
17
|
web_path = File.join(absolute_path, 'web')
|
18
18
|
FileUtils.mkdir_p web_path
|
19
19
|
Dir.chdir web_path do
|
20
20
|
name = File.basename(absolute_path)
|
21
|
-
system 'npx', 'react-gamefic
|
21
|
+
system 'npx', '-y', "react-gamefic#{version}", '--name', name, '--class', 'GAMEFIC_PLOT_CLASS', '--path', '../lib'
|
22
22
|
puts 'The web app is ready.'
|
23
23
|
puts 'Run `rake web:run` to start the app in dev mode.'
|
24
24
|
end
|
data/lib/gamefic-sdk/tasks.rb
CHANGED
@@ -18,9 +18,8 @@ module Gamefic::Sdk::Tasks
|
|
18
18
|
Ruby.new.build
|
19
19
|
end
|
20
20
|
|
21
|
-
define_task
|
22
|
-
|
23
|
-
end
|
21
|
+
Rake::Task.define_task('web:generate', [:version]) { |_, args| Web.new.generate(args[:version]) }
|
22
|
+
.tap { |task| task.add_description 'Generate a web app' }
|
24
23
|
|
25
24
|
define_task 'web:run', 'Run a standalone web app' do
|
26
25
|
Web.new.run
|
@@ -31,7 +30,7 @@ module Gamefic::Sdk::Tasks
|
|
31
30
|
end
|
32
31
|
end
|
33
32
|
|
34
|
-
def define_task
|
33
|
+
def define_task(name, desc, &block)
|
35
34
|
return if Rake::Task.task_defined?(name)
|
36
35
|
|
37
36
|
# @type [Rake::Task]
|
data/lib/gamefic-sdk/version.rb
CHANGED
@@ -13,9 +13,9 @@ Opal::RSpec::RakeTask.new(:opal) do |_, config|
|
|
13
13
|
Bundler.definition
|
14
14
|
.dependencies_for([:default])
|
15
15
|
.each { |dep| Opal.use_gem dep.name }
|
16
|
-
Opal.append_path __dir__
|
17
16
|
Opal.append_path File.join(__dir__, 'lib')
|
17
|
+
config.default_path = 'spec'
|
18
18
|
config.pattern = 'spec/**/*_spec.rb'
|
19
|
-
config.requires = ['
|
19
|
+
config.requires = ['opal_helper']
|
20
20
|
end
|
21
21
|
<% end %>
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gamefic-sdk
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.2.
|
4
|
+
version: 3.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fred Snyder
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-08-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: gamefic
|