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
I have a script that combines multiple steps, like a git commit, npm version, git push, git push --tags, and jitsu deploy, all into one command. Because I'm attempting to streamline things, I put a -c on the jitsu deploy to skip the package.json write warning. I noticed today that this -c essentially answers yes to the prompt: Continue without updating? Bad things might happen (no):, which is probably not a good idea.
In this case I think it's ok to ignore the -c flag and require user input, or probably more appropriately, exit(1) with a message that -c won't bypass a new version. If it's important for people to be able to ignore new versions, I'd recommend the addition of a new flag for that purpose (perhaps -cv).
The text was updated successfully, but these errors were encountered:
This is a good point, however, I am inclined to leave it as is as the -c was intended to skip prompting the user for anything that has a default value, for the primary use for automatic scripting(ie no user around). The second reason, is generally we release in patches, and while it is important to update, patches are generally non breaking, and skipping over this would be aceptable generally.
I think it'd be a good Idea to continue as is for patch releases and exit as you mentioned for major and minor releases--with of course an adequate warning/error message.
Sounds good to me. I guess the change, then, would be that a patch releases would default to yes (so -c can continue to ignore it) and set the default for major + minor releases to no so that -c will exit.
I have a script that combines multiple steps, like a
git commit
,npm version
,git push
,git push --tags
, andjitsu deploy
, all into one command. Because I'm attempting to streamline things, I put a-c
on the jitsu deploy to skip the package.json write warning. I noticed today that this -c essentially answers yes to the prompt: Continue without updating? Bad things might happen (no):, which is probably not a good idea.In this case I think it's ok to ignore the -c flag and require user input, or probably more appropriately,
exit(1)
with a message that -c won't bypass a new version. If it's important for people to be able to ignore new versions, I'd recommend the addition of a new flag for that purpose (perhaps-cv
).The text was updated successfully, but these errors were encountered: