gettc 1.7.4 → 1.7.5

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: 5fa5403ae570ae9da9c113fe95c2682910c2aab1
4
- data.tar.gz: 986bf0c6c65531343df0eb96078eba8c20baab3c
3
+ metadata.gz: 0a749b72f782e9dd4eb99402eef64b9f522dab5e
4
+ data.tar.gz: bd0188164895468f19e6bac14a14ac166f5e8bac
5
5
  SHA512:
6
- metadata.gz: 0a4cec8eb2ce9b96142f968e4fea084857936570cc5c5335adb731c776fc370967557533844cd5992abcd1fe5fd1a496919917f815497ea000b5c252a23f1993
7
- data.tar.gz: 917af0ed331cb0baeac98a3b6348c8496443f809cbe6f8dfc780bab0ba172145bc8141b8b5cf30aa46fa519caa9ccf181f8b5851417f92a2223ed5fd97b0a02b
6
+ metadata.gz: 28c5e11d377ade6b796431b3fa8e0637a2c796aad1f3978dc08fca0487283e42dde54f1c1c9fd2f1c3cd4caa28e813819a46e13a741a564259c8e980efe68a2c
7
+ data.tar.gz: 3dbbfd3dd916f2428a8a4222466af226fbf227f8170fc56967e1f5ebe44fd760afa63d754ee31e93262a5fdb0a00aee3b4b6f597574f55f91f07535fd91e6d02
data/bin/gettc CHANGED
File without changes
data/core/lib/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Gettc
2
- VERSION = "1.7.4"
2
+ VERSION = "1.7.5"
3
3
  end
data/dist/config.yml CHANGED
@@ -1,3 +1,3 @@
1
1
  username: gettc
2
2
  password: algorithm
3
- version: 1.7.4
3
+ version: 1.7.5
@@ -13,10 +13,13 @@ command_exists () {
13
13
 
14
14
  timeit () {
15
15
  if command_exists /usr/bin/time ; then
16
- /usr/bin/time -o /dev/null echo "Testing availability of the time command" >/dev/null
16
+ /usr/bin/time -o /dev/null echo "testing availability of the time command" &>/dev/null
17
17
  if [ $? -eq 0 ]; then
18
18
  /usr/bin/time -o $ostream "$1" "$2" "$3" "$4" "$5" "$6" "$7" "$8" "$9"
19
19
  return
20
+ elif [ $mode = 'verbose' ]; then
21
+ /usr/bin/time "$1" "$2" "$3" "$4" "$5" "$6" "$7" "$8" "$9"
22
+ return
20
23
  fi
21
24
  elif [ $mode = 'verbose' ]; then
22
25
  if command_exists time ; then
@@ -43,17 +46,17 @@ view_file () {
43
46
  }
44
47
 
45
48
  report_case () {
46
- write ' Input: '
49
+ write ' input: '
47
50
  view_file "$data_d/$test_case.in"
48
- write ' Expected: '
51
+ write ' expected: '
49
52
  view_file "$data_d/$test_case.out"
50
- write ' Received: '
53
+ write ' received: '
51
54
  view_file "$output_d/$test_case.out"
52
55
  }
53
56
 
54
57
  init () {
55
- export TIME="Time: %es - Memory: %MK"
56
- export TIMEFORMAT=%3lR
58
+ export time="time: %es - memory: %mk"
59
+ export timeformat=%3lr
57
60
 
58
61
  if [ ! -d "$output_d" ]; then
59
62
  mkdir "$output_d"
@@ -91,37 +94,37 @@ main () {
91
94
  test_case=`basename "$input"`
92
95
  test_case=${test_case%.in}
93
96
 
94
- write "Check $test_case ... "
97
+ write "check $test_case ... "
95
98
  timeit "$solver" "$data_d/$test_case.in" "$output_d/$test_case.out"
96
99
  "$checker" "$data_d/$test_case.out" "$output_d/$test_case.out" > $ostream
97
100
  retcode=$?
98
101
 
99
102
  if [ $retcode -eq 0 ]; then
100
- puts 'Passed'
103
+ puts 'passed'
101
104
 
102
105
  elif [ $retcode -eq 1 ]; then
103
106
  fails=$(( fails + 1 ))
104
107
  failstr="$failstr $test_case"
105
- puts 'Failed'
108
+ puts 'failed'
106
109
  report_case "$test_case"
107
110
 
108
111
  else
109
112
  errors=$(( errors + 1 ))
110
113
  errorstr="$errorstr $test_case"
111
- puts 'Error'
114
+ puts 'error'
112
115
  report_case "$test_case"
113
116
  fi
114
117
  fi
115
118
  done
116
119
  echo "$cases cases checked, $fails failed, $errors errored"
117
120
  if [ $fails -gt 0 ]; then
118
- echo "Failed cases:${failstr}"
121
+ echo "failed cases:${failstr}"
119
122
  fi
120
123
  if [ $errors -gt 0 ]; then
121
- echo "Errored cases:${errorstr}"
124
+ echo "errored cases:${errorstr}"
122
125
  fi
123
126
 
124
127
  }
125
128
 
126
129
  init
127
- main
130
+ main
metadata CHANGED
@@ -1,41 +1,41 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gettc
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.7.4
4
+ version: 1.7.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Seri
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-10-11 00:00:00.000000000 Z
11
+ date: 2015-02-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: hpricot
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '>='
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: '0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - '>='
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: '0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rdiscount
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - '>='
31
+ - - ">="
32
32
  - !ruby/object:Gem::Version
33
33
  version: '0'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - '>='
38
+ - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
41
  description: Given a TopCoder problem ID, gettc downloads the problem specification,
@@ -115,12 +115,12 @@ require_paths:
115
115
  - core/lib
116
116
  required_ruby_version: !ruby/object:Gem::Requirement
117
117
  requirements:
118
- - - '>='
118
+ - - ">="
119
119
  - !ruby/object:Gem::Version
120
120
  version: '0'
121
121
  required_rubygems_version: !ruby/object:Gem::Requirement
122
122
  requirements:
123
- - - '>='
123
+ - - ">="
124
124
  - !ruby/object:Gem::Version
125
125
  version: '0'
126
126
  requirements: []