Update faas-cli new to use stack.yaml as a default #1005
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Update
faas-cli new
to use stack.yaml as a defaultUpdates faas-cli new to create a stack.yaml file instead of a YAML file named after the function. This is to help users discover that stack.yaml does not require a --yaml or -f flag which can become cumbersome.
When a stack.yaml or the file specified via -f already exists the new command will now prompt users to use
--append
Additional changes:
Motivation and Context
Requested a number of times over the years, I also find it more convenient to work from a file where a separate
-f
parameter isn't needed for each commandHow Has This Been Tested?
Various manual tests and the unit tests needed updates since there were test tables which wrote out different names which started to conflict with the new behaviour described.
Types of changes
Checklist:
Certain blog posts may need an update if there are any commands such as
mv fn.yml stack.yml
, which could be tricky to find. Perhaps a regex in the docs and the website would be a good starting point.