GithubHelp home page GithubHelp logo

Comments (17)

sund avatar sund commented on June 25, 2024 1

I would also like to see rsync-style exclusion and inclusion, i.e. from the rsync help:

--exclude=PATTERN     exclude files matching PATTERN

--exclude-from=FILE     read exclude patterns from FILE

--include=PATTERN     don't exclude files matching PATTERN

--include-from=FILE     read include patterns from FILE

Just my thoughts.

from b2_command_line_tool.

bwbeach avatar bwbeach commented on June 25, 2024

Good idea.

Do you want the excluded things to be wildcards? Regexp or glob? Match the entire path, or just the file name?

I assume that if a folder is excluded, everything under it should be excluded, too.

from b2_command_line_tool.

segphault avatar segphault commented on June 25, 2024

For the case that I care about personally, I want to be able to match just the file name rather than the whole path, but I could see the latter also being useful in some situations. I'd like to be able to do something like --exclude "node_modules" and have it exclude directories that match that name everywhere they appear in the hierarchy.

Wildcards would also be great, I think either glob or regex would work well. And yep, it'd also skip the contents of excluded folders. Thanks!

from b2_command_line_tool.

segphault avatar segphault commented on June 25, 2024

I decided to take a crack at implementing this myself. Given the way that the sync feature builds its file list, matching against the full path ended up being the most practical and least intrusive approach. I also decided on using a regex for the match.

from b2_command_line_tool.

ppolewicz avatar ppolewicz commented on June 25, 2024

@sund this seems like a very small change after #153 is merged. Would you like to implement the options you mentioned?

from b2_command_line_tool.

TJC avatar TJC commented on June 25, 2024

Just wanted to say -- I think you should try and implement the same exclude patterns as rsync; they've become reasonably well-understood by many people, and supported by third-party apps.

from b2_command_line_tool.

ppolewicz avatar ppolewicz commented on June 25, 2024

@TJC @sund @segphault do you still need this?

from b2_command_line_tool.

simongreen-net avatar simongreen-net commented on June 25, 2024

I would like to see this option.

from b2_command_line_tool.

ppolewicz avatar ppolewicz commented on June 25, 2024

@simongreen-net okay. Would you like to implement it?

We encourage outside contributors to perform changes on our codebase. Many such changes have been merged already. In order to make it easier to contribute, core developers of this project:

  • provide guidance (through the issue reporting system)
  • provide tool assisted code review (through the Pull Request system)
  • maintain a set of integration tests (run with a production cloud)
  • maintain a set of (well over a hundred) unit tests
  • automatically run unit tests on 14 versions of python (including osx, Jython and pypy)
  • format the code automatically using yapf
  • use static code analysis to find subtle/potential issues with maintainability
  • maintain other Continous Integration tools (coverage tracker)

this particular change is rather easy to implement.

from b2_command_line_tool.

simongreen-net avatar simongreen-net commented on June 25, 2024

Sorry, my Python skills aren't at a level where I would be able to write a patch.

from b2_command_line_tool.

sund avatar sund commented on June 25, 2024

I would also like this. But, like, @simongreen-net my python-fu depends on google more than it should.

from b2_command_line_tool.

ppolewicz avatar ppolewicz commented on June 25, 2024

ok, I have somebody working on this. Assigning myself as a placeholder.

from b2_command_line_tool.

TJC avatar TJC commented on June 25, 2024

@ppolewicz -- Yes, I'd still like to see this feature.. but my Python skills aren't really up there, sorry.

from b2_command_line_tool.

therecluse26 avatar therecluse26 commented on June 25, 2024

Just my two cents... I think that instead of (or inaddition to) having a regex-based ignore function it'd be way more helpful to enable a sort of "ignore" file with a list of all the excluded sync directories, much like the way that the .gitignore file works.

from b2_command_line_tool.

dougwollison avatar dougwollison commented on June 25, 2024

@therecluse26 agreed. I'm personally very fond of the --filter=[file] option in rsync; I can have a nice include/exclude ruleset so that I can sync just what I need.

from b2_command_line_tool.

therecluse26 avatar therecluse26 commented on June 25, 2024

Any updates on this?

from b2_command_line_tool.

ppolewicz avatar ppolewicz commented on June 25, 2024

#244 has been merged

as for --exclude-from=FILE and --include-from=FILE, maybe one day someone will contribute it, when doing so please reference this issue. For now, lets close it.

from b2_command_line_tool.

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.