From 0b3f285e2605cae65418561b2c2f5265a1a0f35c Mon Sep 17 00:00:00 2001 From: DM Date: Tue, 16 May 2017 11:38:06 +0300 Subject: [PATCH] Stop packaging test files with the gem It reduces the size of the gem by half, from 645K to 294K. The default for new gems (created by bundler) is not to include test files. See bundler/bundler#3207 --- newrelic_rpm.gemspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/newrelic_rpm.gemspec b/newrelic_rpm.gemspec index 272b7c1b07..16060249d5 100644 --- a/newrelic_rpm.gemspec +++ b/newrelic_rpm.gemspec @@ -31,7 +31,7 @@ EOS "newrelic.yml" ] - file_list = `git ls-files`.split + file_list = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) } build_file_path = 'lib/new_relic/build.rb' file_list << build_file_path if File.exist?(build_file_path) s.files = file_list