fontana_client_support 0.8.2 → 0.8.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b1e0eaee551b52935db2ca937c66dfc967885e68
4
- data.tar.gz: ee41bfa52d5daca6d1a95c83caca2e84c9f798ec
3
+ metadata.gz: 7af75a6d013efb9a724ee1d8441de8d32b16051f
4
+ data.tar.gz: 91e4f38c29d0fcea7be9fb71a2c778b94d686428
5
5
  SHA512:
6
- metadata.gz: 834f2c77e2c8aad990b4927bc91db09245ab5c500831c310ca9674e97edf68dad2f8ca0553b14919f66a36be3aa14544d9e0dd673fe25214ca65dd24f715b240
7
- data.tar.gz: 33833900e67a517676f7b52591723433ece9e31835d5f985d39568e0bb7ddc1fbeed19caf83e380967ac4fba51e2966531a90fb30649d9e2bb2c49893eff11cb
6
+ metadata.gz: abf62ca19207aef50433a567e3d011108bc39536ec53f9485892f195ddb751bbf7f378c818e616dcde0c8f2d3f1aca377f8c44c229834a741ce3b5988c822229
7
+ data.tar.gz: c6cff3ad9313a31e5e4fbf395860f22a663ea6b56b4a6a6394831075e57e2ef455f7036dcfb350a4de2f70a079d0c9be48b0a3e71244c2881d24264f0fca3b4a
@@ -29,7 +29,7 @@ module Fontana
29
29
 
30
30
  def fontana_task(name, options = {})
31
31
  full_name = (@namespaces + [name]).join(':')
32
- task name do
32
+ task(name => :"bundle:unset_env") do
33
33
  call_fontana_task(full_name, options)
34
34
  end
35
35
  end
@@ -0,0 +1,18 @@
1
+ # -*- coding: utf-8 -*-
2
+ require 'fontana_client_support'
3
+
4
+ # http://bundler.io/v1.3/bundle_config.html
5
+ namespace :bundle do
6
+
7
+ task :unset_env_bundle_environments do
8
+ targets = ENV.keys.select{|k| k =~ /\ABUNDLE_/}
9
+ targets.each{|t| ENV.delete(t) }
10
+ end
11
+
12
+ task :unset_env_gem_home do
13
+ ENV.delete("GEM_HOME")
14
+ end
15
+
16
+ task :unset_env => [:unset_env_bundle_environments, :unset_env_gem_home]
17
+
18
+ end
@@ -32,7 +32,7 @@ end
32
32
  commands.each do |cmd, description|
33
33
 
34
34
  desc "@#{app_mode} #{description}"
35
- task cmd do
35
+ task(cmd => :"bundle:unset_env") do
36
36
  s = "#{cmd_base} #{cmd}"
37
37
  options_str = ENV['OPTIONS']
38
38
  unless options_str.nil? || options_str.empty?
@@ -28,7 +28,7 @@ end
28
28
  https_env_str = build_env_str(https_env)
29
29
 
30
30
  # desc "update VersionSet entries' versions and copy collections"
31
- task(:update_version_set_entries) do
31
+ task(:update_version_set_entries => :"bundle:unset_env") do
32
32
  if ENV["GSS_VERSION_SET_FIXTURE_FILEPATH"]
33
33
  system_at_vendor_fontana!(http_env_str + " rake version_set:update_entry_versions")
34
34
  end
@@ -49,7 +49,7 @@ end
49
49
  launch_https_server: https_fg_cmd,
50
50
  launch_https_server_daemon: https_bg_cmd,
51
51
  }.each do |name, cmd|
52
- task(name){ system_at_vendor_fontana!(cmd) }
52
+ task(name => :"bundle:unset_env"){ system_at_vendor_fontana!(cmd) }
53
53
  end
54
54
 
55
55
  task_sequential :launch_server_daemons, [
@@ -60,8 +60,8 @@ end
60
60
  ]
61
61
 
62
62
  spawn_env = {FONTANA_APP_MODE: app_mode, BUNDLE_GEMFILE: "Gemfile-LibgssTest" }
63
- task(:spawn_http_server){ spawn_at_vendor_fontana_with_sweeper(http_env, http_base_cmd, out: "/dev/null") }
64
- task(:spawn_https_server){ spawn_at_vendor_fontana_with_sweeper(https_env, https_base_cmd, out: "/dev/null") }
63
+ task(:spawn_http_server => :"bundle:unset_env"){ spawn_at_vendor_fontana_with_sweeper(http_env , http_base_cmd , out: "/dev/null") }
64
+ task(:spawn_https_server => :"bundle:unset_env"){ spawn_at_vendor_fontana_with_sweeper(https_env, https_base_cmd, out: "/dev/null") }
65
65
 
66
66
  task_sequential :spawn_servers, [
67
67
  :"#{app_mode}:server:update_version_set_entries",
@@ -91,6 +91,8 @@ namespace :vendor do
91
91
 
92
92
  task :bundle_install do
93
93
  fileutils.chdir(FontanaClientSupport.vendor_fontana) do
94
+ # 開発環境での使用を想定しているので(ステージング、本番ではfontanaをデプロイするので)
95
+ # ここでは --path=vendor/bundle を指定しない
94
96
  system!("BUNDLE_GEMFILE=#{Fontana.gemfile} bundle install")
95
97
  end
96
98
  end
@@ -110,7 +112,7 @@ namespace :vendor do
110
112
  end
111
113
  end
112
114
 
113
- task :db_drop do
115
+ task :db_drop => :"bundle:unset_env" do
114
116
  fileutils.chdir(FontanaClientSupport.vendor_fontana) do
115
117
  system!("BUNDLE_GEMFILE=#{Fontana.gemfile} bundle exec rake db:drop")
116
118
  end
@@ -1,3 +1,3 @@
1
1
  module FontanaClientSupport
2
- VERSION = "0.8.2"
2
+ VERSION = "0.8.3"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fontana_client_support
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.2
4
+ version: 0.8.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - akima
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-09-27 00:00:00.000000000 Z
11
+ date: 2013-09-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -108,6 +108,7 @@ files:
108
108
  - lib/fontana_client_support/tasks.rb
109
109
  - lib/fontana_client_support/tasks/app_mode.rake
110
110
  - lib/fontana_client_support/tasks/app_seed.rake
111
+ - lib/fontana_client_support/tasks/bundle.rake
111
112
  - lib/fontana_client_support/tasks/config_server.rake
112
113
  - lib/fontana_client_support/tasks/db.rake
113
114
  - lib/fontana_client_support/tasks/delayed_job.rake