cor 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/Gemfile +4 -0
- data/LICENSE +22 -0
- data/README.md +31 -0
- data/Rakefile +1 -0
- data/bin/cor +10 -0
- data/cor.gemspec +25 -0
- data/lib/cor.rb +88 -0
- data/lib/cor/version.rb +3 -0
- data/template_rmake.yml +3 -0
- metadata +112 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: c5f181a615478a449323df206250ba26307c279a
|
4
|
+
data.tar.gz: 66bb390b9d6db3193e5dec6e61d5cf7cdc61b4fb
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: f2bc393bd6f67ab9e8f78f948a1657f12b355a8e3fd0997784d692df61bbbd5a2194dcb0c9fa1e423923be118d13f0354e5513d4ce8d159af73774a13552ea21
|
7
|
+
data.tar.gz: 79f6f61ffd1febbe20d36e80d991edcc82e266fc401ecffecead3f069273f4600c138cd394dae31d898eb84eb1b67d907f45f01dcb6ab21b912884c953e7600c
|
data/Gemfile
ADDED
data/LICENSE
ADDED
@@ -0,0 +1,22 @@
|
|
1
|
+
Copyright (c) 2014 akasata
|
2
|
+
|
3
|
+
MIT License
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
6
|
+
a copy of this software and associated documentation files (the
|
7
|
+
"Software"), to deal in the Software without restriction, including
|
8
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
9
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
10
|
+
permit persons to whom the Software is furnished to do so, subject to
|
11
|
+
the following conditions:
|
12
|
+
|
13
|
+
The above copyright notice and this permission notice shall be
|
14
|
+
included in all copies or substantial portions of the Software.
|
15
|
+
|
16
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
17
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
18
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
19
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
20
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
21
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
22
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,31 @@
|
|
1
|
+
# Cor
|
2
|
+
|
3
|
+
Sorry, Japanese version only.
|
4
|
+
|
5
|
+
## Installation
|
6
|
+
|
7
|
+
Add this line to your application's Gemfile:
|
8
|
+
|
9
|
+
gem 'cor'
|
10
|
+
|
11
|
+
And then execute:
|
12
|
+
|
13
|
+
$ bundle
|
14
|
+
|
15
|
+
Or install it yourself as:
|
16
|
+
|
17
|
+
$ gem install cor
|
18
|
+
|
19
|
+
## Usage
|
20
|
+
|
21
|
+
###Initialize
|
22
|
+
|
23
|
+
$ cor init
|
24
|
+
|
25
|
+
###Create new project.
|
26
|
+
|
27
|
+
$ cor project:create [project_type] [dir_name]
|
28
|
+
|
29
|
+
For example.
|
30
|
+
|
31
|
+
$ cor project:create game my_game
|
data/Rakefile
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
require "bundler/gem_tasks"
|
data/bin/cor
ADDED
data/cor.gemspec
ADDED
@@ -0,0 +1,25 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
lib = File.expand_path('../lib', __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require 'cor/version'
|
5
|
+
|
6
|
+
Gem::Specification.new do |spec|
|
7
|
+
spec.name = 'cor'
|
8
|
+
spec.version = Cor::VERSION
|
9
|
+
spec.authors = ['akasata']
|
10
|
+
spec.email = ['akasata@rmake.net']
|
11
|
+
spec.description = %q{This gem provides convenient commands for Code on Rmake. (Sorry, Japanese version only.)}
|
12
|
+
spec.summary = %q{This gem provides convenient commands for Code on Rmake. (Sorry, Japanese version only.)}
|
13
|
+
spec.homepage = 'https://core.rmake.jp/'
|
14
|
+
spec.license = 'MIT'
|
15
|
+
|
16
|
+
spec.files = Dir['Gemfile', 'README.md', 'cor.gemspec', 'LICENSE', 'Rakefile', 'template_rmake.yml', 'lib/*', 'lib/*/*', 'bin/*']
|
17
|
+
spec.executables = ['cor'] # spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
18
|
+
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
19
|
+
spec.require_paths = ['lib']
|
20
|
+
|
21
|
+
spec.add_development_dependency 'bundler', '~> 1.3'
|
22
|
+
spec.add_development_dependency 'rake'
|
23
|
+
spec.add_dependency 'httpclient'
|
24
|
+
spec.add_dependency 'rmake-notation'
|
25
|
+
end
|
data/lib/cor.rb
ADDED
@@ -0,0 +1,88 @@
|
|
1
|
+
require 'cor/version'
|
2
|
+
require 'fileutils'
|
3
|
+
|
4
|
+
module Cor
|
5
|
+
Project_Types = %w(game app application library exp experimentation editor)
|
6
|
+
Platform_Types = %w(Android Windows iOS)
|
7
|
+
|
8
|
+
class Executor
|
9
|
+
def self.version(args)
|
10
|
+
p "Code on Rmake gem Version #{Cor::VERSION}"
|
11
|
+
end
|
12
|
+
|
13
|
+
def self.call_command(args)
|
14
|
+
command = self.analyze_argument(args)
|
15
|
+
|
16
|
+
if self.methods(false).include?(command[:command])
|
17
|
+
self.send(command[:command], command[:args])
|
18
|
+
else
|
19
|
+
p "undefined command #{args[0]}"
|
20
|
+
p "ARGS: #{args.join(', ')}"
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
24
|
+
def self.analyze_argument(args)
|
25
|
+
result = {
|
26
|
+
:command => args.shift.gsub(':', '_').to_sym,
|
27
|
+
:args => args
|
28
|
+
}
|
29
|
+
|
30
|
+
result
|
31
|
+
end
|
32
|
+
|
33
|
+
def self.init(args)
|
34
|
+
FileUtils.mkdir_p(%w(./bin ./projects ./materials ./packages))
|
35
|
+
unless File.exists?('./rmake.yml')
|
36
|
+
source_root = File.expand_path('..', File.dirname(__FILE__))
|
37
|
+
FileUtils.cp("#{source_root}/template_rmake.yml", './rmake.yml')
|
38
|
+
end
|
39
|
+
end
|
40
|
+
|
41
|
+
def self.project_create(args)
|
42
|
+
project_type = args[0]
|
43
|
+
project_name = args[1].to_s
|
44
|
+
|
45
|
+
unless Cor::Project_Types.include? project_type
|
46
|
+
p "Wrong Project Type #{project_type}"
|
47
|
+
return
|
48
|
+
end
|
49
|
+
|
50
|
+
if project_name =~ /\w+/
|
51
|
+
project_dir = "./projects/#{project_name}"
|
52
|
+
if !File.exists?(project_dir)
|
53
|
+
FileUtils.mkdir_p(%W(#{project_dir} #{project_dir}/materials #{project_dir}/data #{project_dir}/src))
|
54
|
+
else
|
55
|
+
p "#{project_name} Project is already exists. "
|
56
|
+
end
|
57
|
+
else
|
58
|
+
p "Wrong Project Name #{project_name}. You can use [a-zA-Z_]."
|
59
|
+
end
|
60
|
+
end
|
61
|
+
|
62
|
+
def self.project_packaging(args)
|
63
|
+
|
64
|
+
end
|
65
|
+
|
66
|
+
def self.project_checkout(args)
|
67
|
+
|
68
|
+
end
|
69
|
+
|
70
|
+
def self.project_upload(args)
|
71
|
+
|
72
|
+
end
|
73
|
+
|
74
|
+
def self.project_release(args)
|
75
|
+
|
76
|
+
end
|
77
|
+
|
78
|
+
def self.install(args)
|
79
|
+
|
80
|
+
end
|
81
|
+
|
82
|
+
def self.update(args)
|
83
|
+
|
84
|
+
end
|
85
|
+
|
86
|
+
|
87
|
+
end
|
88
|
+
end
|
data/lib/cor/version.rb
ADDED
data/template_rmake.yml
ADDED
metadata
ADDED
@@ -0,0 +1,112 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: cor
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.3
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- akasata
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2014-02-15 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: bundler
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ~>
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '1.3'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ~>
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '1.3'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rake
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - '>='
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - '>='
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: httpclient
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - '>='
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0'
|
48
|
+
type: :runtime
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - '>='
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: rmake-notation
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - '>='
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :runtime
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - '>='
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
description: This gem provides convenient commands for Code on Rmake. (Sorry, Japanese
|
70
|
+
version only.)
|
71
|
+
email:
|
72
|
+
- akasata@rmake.net
|
73
|
+
executables:
|
74
|
+
- cor
|
75
|
+
extensions: []
|
76
|
+
extra_rdoc_files: []
|
77
|
+
files:
|
78
|
+
- Gemfile
|
79
|
+
- README.md
|
80
|
+
- cor.gemspec
|
81
|
+
- LICENSE
|
82
|
+
- Rakefile
|
83
|
+
- template_rmake.yml
|
84
|
+
- lib/cor.rb
|
85
|
+
- lib/cor/version.rb
|
86
|
+
- bin/cor
|
87
|
+
homepage: https://core.rmake.jp/
|
88
|
+
licenses:
|
89
|
+
- MIT
|
90
|
+
metadata: {}
|
91
|
+
post_install_message:
|
92
|
+
rdoc_options: []
|
93
|
+
require_paths:
|
94
|
+
- lib
|
95
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
96
|
+
requirements:
|
97
|
+
- - '>='
|
98
|
+
- !ruby/object:Gem::Version
|
99
|
+
version: '0'
|
100
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
101
|
+
requirements:
|
102
|
+
- - '>='
|
103
|
+
- !ruby/object:Gem::Version
|
104
|
+
version: '0'
|
105
|
+
requirements: []
|
106
|
+
rubyforge_project:
|
107
|
+
rubygems_version: 2.1.11
|
108
|
+
signing_key:
|
109
|
+
specification_version: 4
|
110
|
+
summary: This gem provides convenient commands for Code on Rmake. (Sorry, Japanese
|
111
|
+
version only.)
|
112
|
+
test_files: []
|