Re: [PATCH v2 3/8] checkout: validate stage and merge option compatibility in checkout_paths()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]




Karthik Nayak <karthik.188@xxxxxxxxx> writes:
> Sorry if I was unclear. I was stating that the condition udner which the
> check runs is now difference. Previously we checked `opts->pathspec.nr`,
> but now `checkout_paths()` is also entered for '--patch' without any
> path spec.
>
> Having a closer look, it seems to be okay. Because in patch mode, each
> of the combinations is already rejected before in `checkout_paths()`.
Yes, that was why I did not see what difference between the code
before and after the change you were concerned about.
> It still might be good to have a sentence in a the commit message, since
> the guard did change and the reasoning why that is safe is not so
> obvious.
Perhaps.
Having done this, I do not particularly think these changes and
refactorings are all that useful. As unit of reusable code, an
entire command (like "git restore") may still be too coarse and
callers would want a finer grained control out of "Git restore
callable from C programmatically, without having to go through
run_command() interface", which means the caller has to still
formulate argv[] array in order to call them. These 8 patches may
give us a good starting point, but it merely scratches the surface.

[Index of Archives] [Linux Kernel Development] [Gcc Help] [IETF Annouce] [DCCP] [Netdev] [Networking] [Security] [V4L] [Bugtraq] [Yosemite] [MIPS Linux] [ARM Linux] [Linux Security] [Linux RAID] [Linux SCSI] [Fedora Users]

(追記) (追記ここまで)
Powered by Linux

AltStyle によって変換されたページ (->オリジナル) /