summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Smith <tsmith@chef.io>2018-12-20 20:49:30 -0800
committerTim Smith <tsmith@chef.io>2018-12-20 20:49:30 -0800
commitc33f37d3e59549c01a61725b9b28bfb7225e2a41 (patch)
treea92dd8692b497284cff4cde19a643b93ffa9f5ca
parent59829fe77f2bb928831a5c8561da2df82d8e314a (diff)
downloadplist-c33f37d3e59549c01a61725b9b28bfb7225e2a41.tar.gz
Only ship the required libs in the gem artifact
This strips the test/development files from the gemspec so that the gem artifact only includes the bare minimum required libraries. This reduces the total install size for applications that bundle this gem. Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r--.travis.yml8
-rw-r--r--plist.gemspec6
2 files changed, 6 insertions, 8 deletions
diff --git a/.travis.yml b/.travis.yml
index b3d53fc..a4874b5 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -8,9 +8,11 @@ rvm:
- 1.9.3
- 2.0.0-p648 # macOS
- 2.1.10
- - 2.2.7
- - 2.3.4
- - 2.4.1
+ - 2.2.10
+ - 2.3.8
+ - 2.4.5
+ - 2.5.3
+ - 2.6
- ruby-head
- jruby-head
before_install: gem install bundler -v '~> 1.14' --conservative
diff --git a/plist.gemspec b/plist.gemspec
index 9b9a3b8..005c747 100644
--- a/plist.gemspec
+++ b/plist.gemspec
@@ -17,11 +17,7 @@ Gem::Specification.new do |spec|
spec.homepage = "https://github.com/patsplat/plist"
spec.license = "MIT"
- spec.files = `git ls-files -z`.split("\x0").reject do |f|
- f.match(%r{^(test|spec|features)/})
- end
- spec.bindir = "exe"
- spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
+ spec.files = %w{LICENSE.txt} + Dir.glob("lib/**/*", File::FNM_DOTMATCH).reject { |f| File.directory?(f) }
spec.require_paths = ["lib"]
spec.add_development_dependency "bundler", "~> 1.14"