Some fixes for action behavior #65
Merged
+537
−460
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.
Per #38, this will now only stash files on your first clone. I'll walk through how this works with an example. The README should be more clear as well so if this seems like sound logic, I'll update that language in this PR.
You are using degit to initialize a repo that has three files:
Where degit.json looks like this:
clone
action, stash the current working directories files – in this case HELLO.md and degit.json – and then do the clone. The current working directory now only contains the repo specified in this action,foo/bar
remove
action here, that proceeds normally on the currently working directory.--force
and clobber any existing files in the working directory if their paths are the same.The reason for stashing and unstashing is it's how you can add files on top of any repos you are cloning.
Does that make sense?