Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

(#14521) Fix install for vendored cfpropertylist code #210

Closed
wants to merge 2 commits into from

2 participants

Hailee Kenney Matthaus Owens
Hailee Kenney
Collaborator
hkenney commented May 16, 2012

In Facter 2.0 we're vendoring some code for cfpropertylist and install.rb mangled the path and did not include the license. This resolves both those issues.

added some commits May 16, 2012
Hailee Kenney (#14521) Ensure install only strips leading lib dir
Prior to this commit, install stripped out all instance of lib,
which was fine, but now we are vendoring code for facts, and we
need that directory to exist for the vendored so that the require
is correct and because that directory contains the license.
4eaa7c4
Hailee Kenney (#14521) Ensure install propagates licenses
Prior to Facter 2.0, we weren't vendoring code that specifically
required a license, so we didn't need to propagate licenses. Now
Facter 2.0 is vendoring code and we need to explicitly include
the license for that code.
0fa58fc
Matthaus Owens
Owner
haus commented May 16, 2012

@hkenney can you retarget the pull request against 2.0rc please?

Hailee Kenney
Collaborator
hkenney commented May 16, 2012

Pull request has been retargeted to 2.0rc:

#211

Hailee Kenney hkenney closed this May 16, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Showing 2 unique commits by 1 author.

May 16, 2012
Hailee Kenney (#14521) Ensure install only strips leading lib dir
Prior to this commit, install stripped out all instance of lib,
which was fine, but now we are vendoring code for facts, and we
need that directory to exist for the vendored so that the require
is correct and because that directory contains the license.
4eaa7c4
Hailee Kenney (#14521) Ensure install propagates licenses
Prior to Facter 2.0, we weren't vendoring code that specifically
required a license, so we didn't need to propagate licenses. Now
Facter 2.0 is vendoring code and we need to explicitly include
the license for that code.
0fa58fc
This page is out of date. Refresh to see the latest.

Showing 1 changed file with 2 additions and 2 deletions. Show diff stats Hide diff stats

  1. 4  install.rb
4  install.rb
@@ -87,7 +87,7 @@ def glob(list)
87 87
 rdoc  = glob(%w{bin/* sbin/* lib/**/*.rb README README-library CHANGELOG TODO Install}).reject { |e| e=~ /\.(bat|cmd)$/ }
88 88
 ri  = glob(%w(bin/*.rb sbin/* lib/**/*.rb)).reject { |e| e=~ /\.(bat|cmd)$/ }
89 89
 man   = glob(%w{man/man8/*})
90  
-libs  = glob(%w{lib/**/*.rb lib/**/*.py})
  90
+libs  = glob(%w{lib/**/*.rb lib/**/*.py lib/**/LICENSE})
91 91
 tests = glob(%w{tests/**/*.rb})
92 92
 
93 93
 def do_bins(bins, target, strip = 's?bin/')
@@ -99,7 +99,7 @@ def do_bins(bins, target, strip = 's?bin/')
99 99
 
100 100
 def do_libs(libs, strip = 'lib/')
101 101
   libs.each do |lf|
102  
-    olf = File.join(InstallOptions.site_dir, lf.gsub(/#{strip}/, ''))
  102
+    olf = File.join(InstallOptions.site_dir, lf.gsub(/^#{strip}/, ''))
103 103
     op = File.dirname(olf)
104 104
     FileUtils.makedirs(op, {:mode => 0755, :verbose => true})
105 105
     FileUtils.chmod(0755, op)
Commit_comment_tip

Tip: You can add notes to lines in a file. Hover to the left of a line to make a note

Something went wrong with that request. Please try again.