requirejs_integrator 1.0.0 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/CHANGELOG.md +4 -0
- data/Gemfile +1 -1
- data/lib/requirejs_integrator.rb +1 -1
- data/lib/requirejs_integrator/tasks.rb +1 -1
- data/lib/requirejs_integrator/tasks/config.rake +8 -10
- data/lib/requirejs_integrator/tasks/rjs.rake +28 -30
- data/lib/requirejs_integrator/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
ODRiZTA2ZTQ5ZTU5NjAzYTRiN2RkNDk5OGIzMGM0YmZiOTc4YWM5Nw==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
OTdkYjg3OTQ1YjE5YmJiNTFkOTQ0OWJjMjc3NDY1YzZkNzJhMjdlNw==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
MTk3MWQ1NjU1NTA0NmE2YjdjMmU4MmZkZmZjZTczMTQ3NDhmODU5NDUyMzBm
|
10
|
+
NzY3ZGRlMjlmOTk0ZWE3OTg0YmE4MTkyYzc5Mzc1OTkwNGZiMzJiMmU0OTky
|
11
|
+
ZWQ0ODlhYzk0ODlmM2NjZTI2OGU2ZjI0OGY0ZTdjODJiODNhMTc=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
ZWU5NDkyNTYwMTkwYjExNGVjMTg5MmJhZWY5Njc0MjFmNWJhN2M3ZTE4OTNi
|
14
|
+
M2FkZWYwZTI4N2NjYzRlMDkyZjMxNzU5OWVmMDRlMjlhYjk0NDhkNjAyZTEw
|
15
|
+
YzI4MjllNDBjYWNhMWFlZTRjZjg4MjE4M2ZiOTlmOTk2YzcwYzg=
|
data/CHANGELOG.md
CHANGED
data/Gemfile
CHANGED
data/lib/requirejs_integrator.rb
CHANGED
@@ -1 +1 @@
|
|
1
|
-
require
|
1
|
+
require "requirejs_integrator/tasks"
|
@@ -17,5 +17,5 @@
|
|
17
17
|
# You should have received a copy of the GNU General Public License
|
18
18
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
19
19
|
|
20
|
-
tasks_path = File.join(File.dirname(__FILE__),
|
20
|
+
tasks_path = File.join(File.dirname(__FILE__), "tasks")
|
21
21
|
Dir["#{tasks_path}/*.rake"].each { |ext| load ext } if defined?(Rake)
|
@@ -17,25 +17,23 @@
|
|
17
17
|
# You should have received a copy of the GNU General Public License
|
18
18
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
19
19
|
|
20
|
-
require
|
21
|
-
require
|
20
|
+
require "system_executor"
|
21
|
+
require "stdout_outputter"
|
22
22
|
|
23
23
|
namespace :ri do
|
24
|
-
|
25
|
-
desc 'Install default r.js config'
|
24
|
+
desc "Install default r.js config"
|
26
25
|
task :config do
|
27
26
|
default_config_path = File.join(
|
28
|
-
Gem.datadir(
|
29
|
-
|
27
|
+
Gem.datadir("requirejs_integrator"),
|
28
|
+
"build_default.js"
|
30
29
|
)
|
31
30
|
current_path = Rake.application.original_dir
|
32
|
-
current_configdir_path = File.join(current_path,
|
33
|
-
current_config_path = File.join(current_configdir_path,
|
31
|
+
current_configdir_path = File.join(current_path, "config")
|
32
|
+
current_config_path = File.join(current_configdir_path, "build.js")
|
34
33
|
unless File.exist?(current_config_path)
|
35
|
-
StdoutOutputter::Outputter.new.write
|
34
|
+
StdoutOutputter::Outputter.new.write "*** Creating default r.js configuration ***"
|
36
35
|
SystemExecutor::Executor.new.run "mkdir -p #{current_configdir_path}"
|
37
36
|
SystemExecutor::Executor.new.run "cp #{default_config_path} #{current_config_path}"
|
38
37
|
end
|
39
38
|
end
|
40
|
-
|
41
39
|
end
|
@@ -17,47 +17,45 @@
|
|
17
17
|
# You should have received a copy of the GNU General Public License
|
18
18
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
19
19
|
|
20
|
-
require
|
21
|
-
require
|
22
|
-
require
|
20
|
+
require "exec_executor"
|
21
|
+
require "system_executor"
|
22
|
+
require "stdout_outputter"
|
23
23
|
|
24
24
|
namespace :ri do
|
25
|
-
|
26
|
-
desc 'Compile js'
|
25
|
+
desc "Compile js"
|
27
26
|
task :compile do
|
28
|
-
rjs_path = File.join(Gem.datadir(
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
27
|
+
rjs_path = File.join(Gem.datadir("requirejs_integrator"), "r.js")
|
28
|
+
project_ui_dir = ENV["PROJECT_UI_DIR"] || "."
|
29
|
+
project_public_dir = ENV["PROJECT_PUBLIC_DIR"] || "public"
|
30
|
+
project_js_dir = ENV["PROJECT_JS_DIR"] || "javascripts"
|
31
|
+
project_rjs_dir = ENV["PROJECT_RJS_DIR"] || "js"
|
32
|
+
app_dir_path = File.join(
|
34
33
|
Rake.application.original_dir,
|
35
|
-
|
36
|
-
|
37
|
-
|
34
|
+
project_ui_dir,
|
35
|
+
project_public_dir,
|
36
|
+
project_js_dir
|
38
37
|
)
|
39
38
|
dir_path = File.join(
|
40
39
|
Rake.application.original_dir,
|
41
|
-
|
42
|
-
|
43
|
-
|
40
|
+
project_ui_dir,
|
41
|
+
project_public_dir,
|
42
|
+
project_rjs_dir
|
44
43
|
)
|
45
|
-
|
44
|
+
main_config_file_path = File.join(
|
46
45
|
Rake.application.original_dir,
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
46
|
+
project_ui_dir,
|
47
|
+
project_public_dir,
|
48
|
+
project_js_dir,
|
49
|
+
"main.js"
|
51
50
|
)
|
52
51
|
StdoutOutputter::Outputter.new.write "*** Compile js files ***"
|
53
|
-
SystemExecutor::Executor.new.run "node #{rjs_path} -o
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
52
|
+
SystemExecutor::Executor.new.run "node #{rjs_path} -o \
|
53
|
+
config/build.js \
|
54
|
+
appDir=#{app_dir_path} \
|
55
|
+
baseUrl=./ \
|
56
|
+
mainConfigFile=#{main_config_file_path} \
|
57
|
+
dir=#{dir_path}"
|
59
58
|
end
|
60
59
|
|
61
|
-
task c: %w
|
62
|
-
|
60
|
+
task c: %w(compile)
|
63
61
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: requirejs_integrator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 2.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Szymon Kopciewski
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-07-
|
11
|
+
date: 2015-07-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: exec_executor
|
@@ -108,7 +108,7 @@ dependencies:
|
|
108
108
|
- - ! '>='
|
109
109
|
- !ruby/object:Gem::Version
|
110
110
|
version: '0'
|
111
|
-
description:
|
111
|
+
description: The tasks for assets managment with requirejs
|
112
112
|
email: s.kopciewski@gmail.com
|
113
113
|
executables: []
|
114
114
|
extensions: []
|
@@ -148,5 +148,5 @@ rubyforge_project:
|
|
148
148
|
rubygems_version: 2.2.5
|
149
149
|
signing_key:
|
150
150
|
specification_version: 4
|
151
|
-
summary:
|
151
|
+
summary: The tasks for assets managment with requirejs
|
152
152
|
test_files: []
|