nsync 0.4.0 → 0.4.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. data/VERSION +1 -1
  2. data/lib/nsync/producer.rb +10 -6
  3. data/nsync.gemspec +1 -1
  4. metadata +2 -2
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.4.0
1
+ 0.4.1
@@ -61,7 +61,8 @@ module Nsync
61
61
  end
62
62
 
63
63
  def latest_changes
64
- diff = repo.git.native('diff', {:full_index => true})
64
+ # TODO: change to using --work-tree in git
65
+ diff = config.cd { repo.git.native('diff', {:full_index => true}) }
65
66
  diff += diff_untracked_files
66
67
 
67
68
  if diff =~ /diff --git a/
@@ -77,11 +78,14 @@ module Nsync
77
78
  # gets untracked files into the diff output
78
79
  # hack from http://stackoverflow.com/questions/855767/can-i-use-git-diff-on-untracked-files
79
80
  def diff_untracked_files
80
- response, err = repo.git.sh(<<-CMD)
81
- git --git-dir='#{repo.git.git_dir}' ls-files -d --others --exclude-standard |
82
- while read -r i; do git --git-dir='#{repo.git.git_dir}' diff -- /dev/null "$i"; done
83
- CMD
84
- response
81
+ # TODO: change to using --work-tree in git
82
+ config.cd do
83
+ response, err = repo.git.sh(<<-CMD)
84
+ git --git-dir='#{repo.git.git_dir}' ls-files -d --others --exclude-standard |
85
+ while read -r i; do git --git-dir='#{repo.git.git_dir}' diff -- /dev/null "$i"; done
86
+ CMD
87
+ response
88
+ end
85
89
  end
86
90
 
87
91
 
data/nsync.gemspec CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{nsync}
8
- s.version = "0.3.0"
8
+ s.version = "0.4.1"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Ben Hughes"]
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 4
8
- - 0
9
- version: 0.4.0
8
+ - 1
9
+ version: 0.4.1
10
10
  platform: ruby
11
11
  authors:
12
12
  - Ben Hughes