Skip to content

Commit 316d1e1

Browse files
nobumatzbot
authored andcommitted
[ruby/tmpdir] Fix for environment without git
ruby/tmpdir@3f1f2260eb
1 parent cbbb98b commit 316d1e1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/tmpdir.gemspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Gem::Specification.new do |spec|
1616
# Specify which files should be added to the gem when it is released.
1717
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
1818
gemspec = File.basename(__FILE__)
19-
spec.files = IO.popen(%w[git ls-files -z], chdir: __dir__, err: IO::NULL) do |ls|
19+
spec.files = IO.popen(%w[git ls-files -z], chdir: __dir__, err: IO::NULL, exception: false) do |ls|
2020
ls.readlines("\x0", chomp: true).reject do |f|
2121
(f == gemspec) ||
2222
f.start_with?(*%w[bin/ test/ spec/ features/ .git Gemfile])

0 commit comments

Comments
 (0)