tbgit 1.0.3 → 1.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/lib/tbgit/version.rb +1 -1
  3. data/lib/tbgit.rb +11 -5
  4. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 0cfbbff80dc9f1e03335253f8bbd6d519ce6f746
4
- data.tar.gz: 9cbbd01fe4c0162aacf11b585868dcdf43fd55de
3
+ metadata.gz: 9c48220747b8b8469cb020d5157afeed832a3871
4
+ data.tar.gz: 22048d8dd2d68fa0359e1866d8f586cb89bbcb4e
5
5
  SHA512:
6
- metadata.gz: 641e35604aed563d2a57d7c808ec9af2d473ddeb6f35d9f74e311cba49bc334b889bf90138e586454530e38af612a22ae43bd77e7425643ba06ca4058fb41a77
7
- data.tar.gz: b6f2cc86546cfa42e966175c729d5420cd16df714596fb65180e1aa5bc40f766210ddc67e509a5586774ed4c950f14cd448d5cc59e122ae461380ccdfc84441b
6
+ metadata.gz: 416be789a42ff7ebc57619d0569b76dcd2545d0c8c2d0cc24e32192b1f391665e04c7866ad05f30be1a4c180ce6e8ef46c3519c95ccac3b31c890abd6bdd0964
7
+ data.tar.gz: 4f2b8b9c7f76a8c5bbf57c7624a33b6b8b259a72ec897c6c36e3c0c06d1c2db1ca720cb8a677dd0168589548e92b9cbecef853b9f5da3d2dbd02388cab1ce51a
data/lib/tbgit/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Tbgit
2
- VERSION = "1.0.3"
2
+ VERSION = "1.0.4"
3
3
  end
data/lib/tbgit.rb CHANGED
@@ -180,20 +180,26 @@ module Main
180
180
  def spec
181
181
  puts "Please specify the relative path from your pwd to the rspec file you would like to spec, eg. 'hw1/spec/spec.rb'"
182
182
  specfile = $stdin.gets.chomp
183
- puts "Where would you like to save the master copy of all results?"
184
- puts "**Must be outside the student's repo directory, eg. '../results.txt'**"
185
- mastercopy = $stdin.gets.chomp
183
+
186
184
  puts "Where would you like to save each student's individual results?"
187
185
  puts "**Must be inside the student's repo directory, eg. 'hw1/spec/results.txt'**"
188
186
  studentcopy = $stdin.gets.chomp
187
+
188
+ puts "In which folder would you like to save a copy of all results?"
189
+ puts "**Must be outside the student's repo directory, eg. '../results'**"
190
+ mastercopy = $stdin.gets.chomp
191
+
192
+ puts "mkdir " + mastercopy
193
+ system "mkdir " + mastercopy
194
+
189
195
  puts "Commit message (commiting each student's results to their repo):"
190
196
  commit_message = $stdin.gets.chomp
197
+
191
198
  confirm("'rspec " + specfile + "' will be executed on each student's local branch. \
192
199
  Individual results will be saved to " + studentcopy + " and master results to " + mastercopy + ". Continue?")
193
200
 
194
201
  on_each_exec(["rspec " +specfile + " > " + studentcopy, #overwrite
195
- "echo '<branch>' >> " + mastercopy,
196
- "cat " + studentcopy + " >> " + mastercopy, #append
202
+ "rspec --format json --out " + mastercopy + "/<branch> " + specfile,
197
203
  "git add --all",
198
204
  "git commit -am '" + commit_message + "'",
199
205
  "git push <branch> <branch>:master"])
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tbgit
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.3
4
+ version: 1.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Charlie Proctor