GithubHelp home page GithubHelp logo

Comments (7)

jaymzh avatar jaymzh commented on April 27, 2024

How about adding Berksfile.lock to your .gitignore?

from grocery-delivery.

wjimenez5271 avatar wjimenez5271 commented on April 27, 2024

That would work. And another option is to ensure the Berksfile.lock is already up to date in your CD pipeline before it gets to grocery delivery. But if neither of these things are done, grocery-delivery will fail so I wonder if we should still make a provision for that situation. Or maybe not, perhaps its better to handle these things outside of grocery-delivery...

from grocery-delivery.

odcinek avatar odcinek commented on April 27, 2024

Seems like for that particular workflow ignoring Berksfile.lock altogether is the right way to go. Since we're doing berks update it's useless to keep it around.

It might make sense to support both:

  • do berks update and .gitignore Berksfile.lock
  • do berks install and depend on Berksfile.lock being provided

from grocery-delivery.

jaymzh avatar jaymzh commented on April 27, 2024

So.. as Marcin pointed out, certainly with berks up, it makes no sense to have a lockfile in git.

While you could do bersk install it toally breaks the GD model and so I don't see us building that workflow.

So, to answer your question... I'm not sure how we would do that... perhaps in that PR you're going to do to add docs for how to use this with berkshelf you'll add the "you must add this to .gitignore"? Or perhaps we start passing in --ignore type flags to all our commands (less thrilled about that, but if they exist I'm not opposed to it).

Thoughts?

from grocery-delivery.

jaymzh avatar jaymzh commented on April 27, 2024

@wjimenez5271 ?

from grocery-delivery.

wjimenez5271 avatar wjimenez5271 commented on April 27, 2024

Sorry, got slammed at work this week.

So something else I've been considering, in some ways use of berks update is really inappropriate for grocery-delivery to be doing in the sense that it's domain is to ensure changes are propagated as defined by the state of the world in git, not resolve or otherwise render those changes (correct if wrong). Now in practice it is convenient for GD to do update since the run will still work even if the developer forgot to, and usually harmless as well.

So perhaps in the interest of usability, and per @odcinek's point, we want to offer both modes, with a strong preface of the risks associated with not using GD to do berks update and resolve dependencies. I'd be really curious to know what Jamie Winsor thinks about this, esp. since the use of Berkshelf in this manner isn't well documented. I happened to mention how we're using Berkshelf with GD at Chefconf this year and he was very supportive of the idea...but I'd certainly like some of his thoughts on specifics like this.

@jaymzh to your thoughts about implementation, I agree another cmd flag for this is undesirable. Maybe we just have an optional config param for berks mode that accompanies the berks related ones, something like strict and relaxed, the former being no berks update or install and requires a lockfile, and the later will run gratuitous berks update and will ignore the lockfile.

from grocery-delivery.

jaymzh avatar jaymzh commented on April 27, 2024

I can't see a sane way to make berks install ever work with GD - they are fundamentally different models. Using berks update to force dependency checking is fine, but you either want to be living off of head or you want to be locking sets of versions. Since we all at least agree that with berks update that .gitignore is the right call, I'm going to close this - and if we decide there is a sane usecase for berks install we can revisit then.

from grocery-delivery.

Related Issues (15)

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.