You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At this point(where we have --pr-remote, --[no-]push, --upstream-remote (#35), and --no-auto-pr (#36) flags, it seems worth considering adding some way to configure user preferences on a global and perhaps local level.
The most obvious solution seems to be using git config since it supports both global and local user configuration already, it is used by cherry-picker already, and therefore should be relatively straight-forward.
Small note here: I think it would be better to choose a different section than cherry-picker as currently cherry-picker suggest to use git config --local --remove-section cherry-picker as last resort for resetting cherry-picker's state.
Of course, there could instead be a single file at some configuration path (~/.config/cherry_picker/preferences.toml?) for setting both global and local level preferences, i.e.:
[global]
upstream_remote = "the_real_deal"pr_remote = "mine"no_auto_pr = true# I'm not entirely sold on the idea of using paths, but it would be the simplest to implement for sure
[local."/home/jack/CPython"]
upstream_remote = "python"
but I don't know if there are any upsides to this over just using git config
The text was updated successfully, but these errors were encountered:
Note: --no-push and -no-auto-pr should ideally be set separately for regular cherry_picker run and for cherry_picker --continue so that one can have a workflow like this (otherwise it won't be possible to configure it as such after #43 is merged) using only the user preferences:
# cherry-pick but don't push:
cherry_picker --no-push COMMIT_SHA1 BRANCH
# after successful cherry-pick, continue with a push and PR using:
cherry_picker --continue
At this point(where we have
--pr-remote
,--[no-]push
,--upstream-remote
(#35), and--no-auto-pr
(#36) flags, it seems worth considering adding some way to configure user preferences on a global and perhaps local level.The most obvious solution seems to be using
git config
since it supports both global and local user configuration already, it is used by cherry-picker already, and therefore should be relatively straight-forward.Small note here: I think it would be better to choose a different section than
cherry-picker
as currently cherry-picker suggest to usegit config --local --remove-section cherry-picker
as last resort for resetting cherry-picker's state.Of course, there could instead be a single file at some configuration path (
~/.config/cherry_picker/preferences.toml
?) for setting both global and local level preferences, i.e.:but I don't know if there are any upsides to this over just using
git config
The text was updated successfully, but these errors were encountered: