git-contest 0.2.3 → 0.2.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- NDc2MTMzZGFkYzRlNzMyYWM1MjA0MzNhOWM1NjQ2NGIzZjhhNzY4ZA==
4
+ MjcwYjUzOGYzYzkwYWEzYjRlMzlkYTk3YTQ0ZTA5OTEzNzBjMDljOQ==
5
5
  data.tar.gz: !binary |-
6
- YjFlZTMzYjVkMTUxMTJhZGNlMzYzOTYxZGZmY2YxODVlZTI1YmI3Yw==
6
+ YmNlNzBkZDBjNWUzZTgyMzMzMDI0ZGVkZDM1MjhjNTE5MGVjYmZlZg==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- NjVjNmM3NDU0ZThiMzFlODBkYjc3MjA0YjE5ZTQyNDJiNTE1ODk2ZTI3NzY0
10
- NDgyOTg0ODAwNzQ4NzFkYjEzZWI2NzYzMzIxZjQ0MDlhNDgxYThjMjNhY2I1
11
- MDJkNDAyNWZhMWYxMmE3NDQ1Y2UxNDBiNmJjMDExMWY3MzUxNzE=
9
+ NDgyZDYxODAyZWVjMDdjZTY0OTJiODQxMDlhZWRhYjRiZDgyMGRjMTE5N2I3
10
+ ZDA2ZGZlZTU1N2JiNTg0ZTQ3OTk0NzhlYmQ0YWFhNzQxYjI4MWY1MGNmODBh
11
+ OGZhYmNkNGUwZGNjNTg1Nzc4YjJkZTY4ZTI0ZDU2ZDgwZGY3ZmU=
12
12
  data.tar.gz: !binary |-
13
- ZDM0ODBmZTExYzgzMWVhM2VhOTlkYTM3Nzk3ZWQ4NjkwMDJjYWNiZjAyNGQy
14
- NzY0NjY0NzIwMDZkZTA3MzY5N2ZmM2UyMTNjZjA2OGYyYzhkODEzNjc5YTkz
15
- ZTM0NTM3MjIzZjRkODhkNDY2NTk0MDg5NDg1ZDNjNjYzODljYTg=
13
+ NzQ3MDMxOTc2NGQ2MGRkMjNkM2ViMGMwYWYzZTZkYTczYmIzYjc2Mjc2Nzk3
14
+ ZmEyNjg4ZjlmNGE4YWYyYjhmYmU1NmQ3N2Q3MDcwMjJiNWIzMWM4YTcxYmY0
15
+ YThlODI3M2I5NTYxZDNiODE5OGQxZDE2M2Y2MjFiM2Q3MDFkYTU=
data/.travis.yml CHANGED
@@ -1,23 +1,27 @@
1
1
  language: ruby
2
+
2
3
  rvm:
3
- - 2.1.*
4
- - 2.0.*
5
- - 1.9.*
4
+ - "2.1"
5
+ - "2.0"
6
+ - "1.9"
7
+
6
8
  before_install:
7
9
  - git config --global user.email "dummy@localhost"
8
- - git config --global user.name "This Is Dummy"
10
+ - git config --global user.name "This Is Dummyyy"
11
+
9
12
  install:
10
13
  - export NOKOGIRI_USE_SYSTEM_LIBRARIES="YES"
11
- - bundle install
14
+ - travis_retry bundle install --jobs=3
12
15
  - bundle exec rake install
16
+
13
17
  script:
14
18
  - bundle exec rake spec
19
+
15
20
  deploy:
16
21
  provider: rubygems
17
22
  api_key:
18
23
  master:
19
24
  secure: "LjL6NrPR/KdkSKgUgixtsWiPH7LZrgZrMG9d66G0CY1HLDUXOY17W7HyAP0PYFVLVrJDM7CRx66PSuadYtyuIY1s0iM5hpEA81MlenxZQoApGcbJb2Zd647SPNk4NM+mZCRt9xJyRqrvHHg1d5+4pQVSHl/lGvuQRGXrYXocGLg="
20
25
  gem:
21
- master:
22
- secure: "Nfw/B5yVdEbf2tULbPlJik/98IolBflsbCFC4pRENVoXS5YdtyGEZlIqCrHJMPjbBCSeSq5qfJzDdnkdhFjCpPymDB4lOKd0p1UgeNws9kxeLcdJKjLZ09lwcfqTObqV7Fa8bB61DjfZ0yVjaq+99/7a9rSeYVK3S2sVQorhBz4="
26
+ master: git-contest
23
27
 
@@ -131,7 +131,7 @@ when "site"
131
131
  end.to_s
132
132
 
133
133
  # set config
134
- File.open($GIT_CONTEST_CONFIG, 'w') {|f| f.write config.to_yaml }
134
+ File.open($git_contest_config, 'w') {|f| f.write config.to_yaml }
135
135
 
136
136
  puts ""
137
137
  puts "updated successfully!!"
@@ -154,7 +154,7 @@ when "site"
154
154
  config = get_config
155
155
  config["sites"].delete site_name
156
156
  # save config
157
- File.open($GIT_CONTEST_CONFIG, 'w') {|f| f.write config.to_yaml }
157
+ File.open($git_contest_config, 'w') {|f| f.write config.to_yaml }
158
158
  puts ""
159
159
  puts "updated successfully!!"
160
160
  puts ""
@@ -221,7 +221,7 @@ when "set"
221
221
  config.deep_merge! new_config
222
222
 
223
223
  # save file
224
- File.open($GIT_CONTEST_CONFIG, 'w') {|f| f.write config.to_yaml }
224
+ File.open($git_contest_config, 'w') {|f| f.write config.to_yaml }
225
225
  elsif ARGV.length == 2
226
226
  # read values from command args
227
227
  keys = ARGV.shift.to_s.strip.split('.')
@@ -243,7 +243,7 @@ when "set"
243
243
  config.deep_merge! new_config
244
244
 
245
245
  # save file
246
- File.open($GIT_CONTEST_CONFIG, 'w') {|f| f.write config.to_yaml }
246
+ File.open($git_contest_config, 'w') {|f| f.write config.to_yaml }
247
247
  else
248
248
  show_set_usage
249
249
  end
@@ -56,8 +56,10 @@ module Contest
56
56
  return "D"
57
57
  when "ruby"
58
58
  return "Ruby"
59
- when "python"
59
+ when "python2"
60
60
  return "Python"
61
+ when "python3"
62
+ return "Python3"
61
63
  when "php"
62
64
  return "PHP"
63
65
  when "javascript"
@@ -35,7 +35,7 @@ module Contest
35
35
  #
36
36
  def self.load_plugins
37
37
  # load drivers
38
- Dir.glob("#{$GIT_CONTEST_HOME}/plugins/**") do |path|
38
+ Dir.glob("#{$git_contest_home}/plugins/**") do |path|
39
39
  require path if /\/.*_driver\.rb$/.match path
40
40
  end
41
41
  end
@@ -17,8 +17,8 @@ def init
17
17
  end
18
18
 
19
19
  def init_global
20
- $GIT_CONTEST_HOME = File.expand_path(ENV['GIT_CONTEST_HOME'] || "~/.git-contest")
21
- $GIT_CONTEST_CONFIG = File.expand_path(ENV['GIT_CONTEST_CONFIG'] || "#{$GIT_CONTEST_HOME}/config.yml")
20
+ $git_contest_home = File.expand_path(ENV['GIT_CONTEST_HOME'] || "~/.git-contest")
21
+ $git_contest_config = File.expand_path(ENV['GIT_CONTEST_CONFIG'] || "#{$git_contest_home}/config.yml")
22
22
  if git_do_no_echo 'branch'
23
23
  $MASTER = git_do 'config --get git.contest.branch.master'
24
24
  $PREFIX = git_do 'config --get git.contest.branch.prefix'
@@ -33,16 +33,16 @@ def init_global
33
33
  end
34
34
 
35
35
  def init_home
36
- if ! FileTest.exists? $GIT_CONTEST_HOME
37
- FileUtils.mkdir $GIT_CONTEST_HOME
36
+ if ! FileTest.exists? $git_contest_home
37
+ FileUtils.mkdir $git_contest_home
38
38
  end
39
- if ! FileTest.exists? $GIT_CONTEST_CONFIG
40
- FileUtils.touch $GIT_CONTEST_CONFIG
39
+ if ! FileTest.exists? $git_contest_config
40
+ FileUtils.touch $git_contest_config
41
41
  end
42
42
  end
43
43
 
44
44
  def get_config
45
- config_path = File.expand_path($GIT_CONTEST_CONFIG)
45
+ config_path = File.expand_path($git_contest_config)
46
46
  YAML.load_file config_path
47
47
  end
48
48
 
@@ -7,6 +7,6 @@
7
7
 
8
8
  module Git
9
9
  module Contest
10
- VERSION = "0.2.3"
10
+ VERSION = "0.2.4"
11
11
  end
12
12
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: git-contest
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 0.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hiroyuki Sano
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-08-28 00:00:00.000000000 Z
11
+ date: 2014-11-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: mechanize
@@ -255,7 +255,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
255
255
  version: '0'
256
256
  requirements: []
257
257
  rubyforge_project:
258
- rubygems_version: 2.4.1
258
+ rubygems_version: 2.4.2
259
259
  signing_key:
260
260
  specification_version: 4
261
261
  summary: The Git Extension for online judges (Codeforces, etc...)