File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -20,11 +20,15 @@ Gem::Specification.new do |spec|
20
20
21
21
# Specify which files should be added to the gem when it is released.
22
22
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
23
- spec . files = Dir . chdir ( File . expand_path ( '..' , __FILE__ ) ) do
24
- `git ls-files -z` . split ( "\x0 " ) . reject { |f | f . match ( %r{^(test|spec|features)/} ) }
23
+ gemspec = File . basename ( __FILE__ )
24
+ spec . files = IO . popen ( %w[ git ls-files -z ] , chdir : __dir__ , err : IO ::NULL ) do |ls |
25
+ ls . readlines ( "\x0 " , chomp : true ) . reject do |f |
26
+ ( f == gemspec ) ||
27
+ f . start_with? ( *%w[ bin/ test/ spec/ features/ .git .github appveyor Gemfile ] )
28
+ end
25
29
end
26
30
spec . bindir = "exe"
27
- spec . executables = spec . files . grep ( %r{^exe /} ) { |f | File . basename ( f ) }
31
+ spec . executables = spec . files . grep ( %r{\A exe /} ) { |f | File . basename ( f ) }
28
32
spec . require_paths = [ "lib" ]
29
33
30
34
spec . add_runtime_dependency "serverkit"
You can’t perform that action at this time.
0 commit comments