Code Monkey home page Code Monkey logo

Comments (4)

jpgrayson avatar jpgrayson commented on September 1, 2024

The case for --3way makes sense to me.

Regarding passing arbitrary options to git apply, I personally do not prefer that approach. Stgit has this kind of arbitrary option pass-through with --diff-opts on several subcommands (diff, show, edit, ...).

One of the problems is CLI discoverability. Stgit's help does not present the user with all the valid/useful diff options. This could be solved with more documentation.

Another problem is that it becomes unclear/opaque as to how user-selected diff options interact with stgit's default diff options. I.e. how does the user know which ones stgit already applies? Or what the behavior will be when a user-provided option conflicts with a stgit default option?

Lastly, it makes the stgit code more complex because in order to have reasonable behaviors when a user-provided option conflicts with stgit's default option set, stgit has to first parse the user's pass-through options and then resolve the conflict somehow. At this point, we are already baking-in knowledge about git's options, so why not explicitly enumerate the useful options as part of stgit's interface?

Anyway, I would be open to a patch to add the --3way option to stg import, along with potentially other options that map to useful git apply modes/options, but I'd need to be sold on the general-purpose pass-through.

from stgit.

jnsnow avatar jnsnow commented on September 1, 2024

OK, I wasn't sure if there would be pushback to a parade of new options, but I can route a --3way option for now and leave something more generic/powerful for another day.

Thank you and sorry for the deluge of issues/emails; but I am very excited to see activity on stgit, which is a tool I love dearly :)

from stgit.

wberrier avatar wberrier commented on September 1, 2024

Another option that I'd be interested in from git-apply is --directory.

The repository I'm importing to doesn't have the same base path as the repository I'm importing from. I'm ok that the generated patches would have different paths. Having this option would help bootstrap the process using stgit instead of manually using git am and git apply.

from stgit.

lkraav avatar lkraav commented on September 1, 2024

Trying to backport https://patchwork.kernel.org/project/linux-pci/cover/[email protected]/ on older kernel, I was reminded stg import --3way sure would be nice.

from stgit.

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.