bourdain 1.2.15 → 1.2.16

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d0546af0081ec0ed6aef62a0ba68b3289f3d5f91
4
- data.tar.gz: 0f14f843d1d4d5e461496ebf728efd29638d9312
3
+ metadata.gz: 43d0df74cf4d0679738900fc8a707bb0414e4ef6
4
+ data.tar.gz: e8ccb3c888a84374040031d5f1e40d7fb85d083a
5
5
  SHA512:
6
- metadata.gz: f68b33cb79ff3f4d79bad1700eb8f0a7c57daf699ff8a0c4144a5a729e0443fa20db9829cefa71de406743f27a50240f942cd56bb0df257e9b166f3f11f68f1b
7
- data.tar.gz: 7adb1947b69a3737a44cd6bfda0c61c0511172b93dbd744eb9ca3943bd3874e4765d9df38455faaa6574ca2c73059726ae675d9f5d7208caa20f919e1ea4a606
6
+ metadata.gz: e5b22536ccced5a9563c35e9ade05e876236c31bb1346098ef24141377083f150f86bc187b34bda6a53cf885d5cc2d7860f0942a5d9f35ee005e9449e3fbd2ae
7
+ data.tar.gz: d49a91e80b2bcf765ccfe0388785dc13937d58278ff4d97a5fac852c743247962da89f30c241ab03878b6bf1e3735f84094b92797921d0305859e6802d989e71
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.2.15
1
+ 1.2.16
@@ -23,24 +23,35 @@ module Bourdain
23
23
  end
24
24
  end
25
25
 
26
+ def repo_dir repo
27
+ File.join(Dir.pwd, repo)
28
+ end
29
+
26
30
  def work_tree repo
27
- "--work-tree=#{File.join(Dir.pwd, repo)}"
31
+ "--work-tree=#{repo_dir repo}"
28
32
  end
29
33
 
30
34
  def git_dir repo
31
- "--git-dir=#{File.join(Dir.pwd, repo, '.git')}"
35
+ "--git-dir=#{File.join repo_dir(repo), '.git'}"
32
36
  end
33
37
 
34
38
  def youre_behind? repo
39
+ `git fetch #{repo_dir repo} >/dev/null 2>&1`
40
+ raise unless $?.exitstatus.zero?
35
41
  `git #{git_dir repo} log ..origin/master --oneline`.split("\n").length > 0
42
+ raise unless $?.exitstatus.zero?
36
43
  end
37
44
 
38
45
  def youre_ahead? repo
46
+ `git fetch #{repo_dir repo} >/dev/null 2>&1`
47
+ raise unless $?.exitstatus.zero?
39
48
  `git #{git_dir repo} log origin/master.. --oneline`.split("\n").length > 0
49
+ raise unless $?.exitstatus.zero?
40
50
  end
41
51
 
42
52
  def youre_dirty? repo
43
53
  `git #{git_dir repo} #{work_tree repo} diff HEAD --numstat`.split("\n").length > 0
54
+ raise unless $?.exitstatus.zero?
44
55
  end
45
56
  end
46
57
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bourdain
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.15
4
+ version: 1.2.16
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sean Clemmer
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-12-17 00:00:00.000000000 Z
11
+ date: 2014-12-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: pmap