Coder Social home page Coder Social logo

Comments (4)

electrical avatar electrical commented on June 19, 2024

I've done some digging when @alexjfisher mentioned it on IRC.
https://github.com/puppetlabs/beaker/blob/master/lib/beaker/host.rb#L390-L392 does a glob of all the potential directories and rejects anything that matches the ignore_re.
The issue with this is that the Regex is not specific enough and matches anything that is in the path.
So if you have a path called /foo/bar/spec/something it gets ignored because it has spec in the path name.
We should only process the ignoring of directories in the source dir it self.

A potential fix is to do f.gsub(source, '') =~ ignore_re at https://github.com/puppetlabs/beaker/blob/master/lib/beaker/host.rb#L391
which strips out the source path so we only evaluate the directories that are in the source path.

@anodelman any opinions on this?

from beaker.

anodelman avatar anodelman commented on June 19, 2024

I think that our scp ignore is pretty much a mess and I'm going to be reviewing it this week. The difficulty here is that some code depends upon our flexible attitude towards what is a match, yet, in this case, it is stabbing us in the back.

What really needs to happen here is better doc-ing that makes it clear what ignore does/doesn't do and then stick to i.

from beaker.

anodelman avatar anodelman commented on June 19, 2024

A fix for this is actually included in #730 - to only match against subdirs of the provided dir.

from beaker.

anodelman avatar anodelman commented on June 19, 2024

PR merged.

from beaker.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.