* Fail (and log message) if attempting to execute git commands in a directory that is not a git-repo.
* Add Test
* Code Formatting
---------
Co-authored-by: Constantin Comendant <constantin@uberagent.com>
Co-authored-by: Stefan Zweifel <stefan@stefanzweifel.dev>
* Add _set_github_output function
* Use _set_github_output in Action
* Add _log function
* Use _log in Action and fix Test Cases
* Update wording in log messages
* Update note about removal of old output syntax
Logic is now encapuslated in a single function. I don’t mind keeping it around until spring / June 2023
* fix crlf test
* add diff check before commit
* add dirty check flag (not sure if needed)
* Update test name and add more assertions
Update test name to make it clear that the Action no longer fails to detect CRLF changes.
* Add Comment to explain why we use git-diff again
* Add test to confirm content changes are commited
* Closes#241
Co-authored-by: Stefan Zweifel <hello@stefanzweifel.io>
* GitHub has deprecated set-output and now needs to add the content to the GITHUB_OUTPUT file
* Update tests too
* Fix tests and shell-format changes
* Revert yarn.lock changes
* Expand file_pattern input
* Expand file pattern array in git-status
* Add Failing Test
* Expand INPUT_FILE_PATTERN
* Fix Shellcheck Issues
* Add test to cover file expansion works when globbing is disabled
* Add explanation to README
This new option will allow users to skip the execution of `git fetch` if it has a negative impact in their workflows.
In a future PR I will probably remove the call to git-fetch interely. It was added in #108 in relation to a problem with slashes in branch names. That problem wasn't properly fixed though.
If git can't automatically figure out if the argument is a branch or
a path, it will need to be told explicitly by using `--`:
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
Fixes: #106