Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

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

Closed
wants to merge 2 commits into from

2 participants

@hkenney
Owner

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.

hkenney added some commits
@hkenney hkenney (#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
@hkenney hkenney (#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
@haus
Owner

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

@hkenney
Owner

Pull request has been retargeted to 2.0rc:

#211

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

    (#14521) Ensure install only strips leading lib dir

    hkenney authored
    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.
  2. @hkenney

    (#14521) Ensure install propagates licenses

    hkenney authored
    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.
This page is out of date. Refresh to see the latest.
Showing with 2 additions and 2 deletions.
  1. +2 −2 install.rb
View
4 install.rb
@@ -87,7 +87,7 @@ def glob(list)
rdoc = glob(%w{bin/* sbin/* lib/**/*.rb README README-library CHANGELOG TODO Install}).reject { |e| e=~ /\.(bat|cmd)$/ }
ri = glob(%w(bin/*.rb sbin/* lib/**/*.rb)).reject { |e| e=~ /\.(bat|cmd)$/ }
man = glob(%w{man/man8/*})
-libs = glob(%w{lib/**/*.rb lib/**/*.py})
+libs = glob(%w{lib/**/*.rb lib/**/*.py lib/**/LICENSE})
tests = glob(%w{tests/**/*.rb})
def do_bins(bins, target, strip = 's?bin/')
@@ -99,7 +99,7 @@ def do_bins(bins, target, strip = 's?bin/')
def do_libs(libs, strip = 'lib/')
libs.each do |lf|
- olf = File.join(InstallOptions.site_dir, lf.gsub(/#{strip}/, ''))
+ olf = File.join(InstallOptions.site_dir, lf.gsub(/^#{strip}/, ''))
op = File.dirname(olf)
FileUtils.makedirs(op, {:mode => 0755, :verbose => true})
FileUtils.chmod(0755, op)
Something went wrong with that request. Please try again.