Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
09a879748c | ||
|
|
71afc9f3b8 | ||
|
|
bb5d1a8f64 | ||
|
|
23b35e63df | ||
|
|
12ed49be65 |
16
HISTORY.md
16
HISTORY.md
@@ -1,5 +1,21 @@
|
||||
# Changelog
|
||||
|
||||
## [v11.4](https://github.com/tj-actions/changed-files/tree/v11.4) (2021-10-30)
|
||||
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v11.3...v11.4)
|
||||
|
||||
**Implemented enhancements:**
|
||||
|
||||
- \[Feature\] Get changed files in all commits in push [\#234](https://github.com/tj-actions/changed-files/issues/234)
|
||||
|
||||
**Merged pull requests:**
|
||||
|
||||
- Updated README.md [\#238](https://github.com/tj-actions/changed-files/pull/238) ([jackton1](https://github.com/jackton1))
|
||||
- Revert "Update base\_sha to use the last commit on the current branch for push event" [\#237](https://github.com/tj-actions/changed-files/pull/237) ([jackton1](https://github.com/jackton1))
|
||||
- Support retrieving changed files between the last remote commit and the current HEAD for push events [\#236](https://github.com/tj-actions/changed-files/pull/236) ([jackton1](https://github.com/jackton1))
|
||||
- Update base\_sha to use the last commit on the current branch for push event [\#235](https://github.com/tj-actions/changed-files/pull/235) ([jackton1](https://github.com/jackton1))
|
||||
- Upgraded to v11.3 [\#233](https://github.com/tj-actions/changed-files/pull/233) ([jackton1](https://github.com/jackton1))
|
||||
|
||||
## [v11.3](https://github.com/tj-actions/changed-files/tree/v11.3) (2021-10-27)
|
||||
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v11.2...v11.3)
|
||||
|
||||
27
README.md
27
README.md
@@ -59,7 +59,7 @@ jobs:
|
||||
|
||||
- name: Get changed files
|
||||
id: changed-files
|
||||
uses: tj-actions/changed-files@v11.3
|
||||
uses: tj-actions/changed-files@v11.4
|
||||
|
||||
- name: List all modified files
|
||||
run: |
|
||||
@@ -122,11 +122,11 @@ jobs:
|
||||
|
||||
- name: Get changed files using defaults
|
||||
id: changed-files
|
||||
uses: tj-actions/changed-files@v11.3
|
||||
uses: tj-actions/changed-files@v11.4
|
||||
|
||||
- name: Get changed files using a comma separator
|
||||
id: changed-files-comma
|
||||
uses: tj-actions/changed-files@v11.3
|
||||
uses: tj-actions/changed-files@v11.4
|
||||
with:
|
||||
separator: ","
|
||||
|
||||
@@ -148,7 +148,7 @@ jobs:
|
||||
|
||||
- name: Get specific changed files
|
||||
id: changed-files-specific
|
||||
uses: tj-actions/changed-files@v11.3
|
||||
uses: tj-actions/changed-files@v11.4
|
||||
with:
|
||||
files: |
|
||||
my-file.txt
|
||||
@@ -186,14 +186,14 @@ jobs:
|
||||
|
||||
- name: Use a source file or list of file(s) to populate to files input.
|
||||
id: changed-files-specific-source-file
|
||||
uses: tj-actions/changed-files@v11.3
|
||||
uses: tj-actions/changed-files@v11.4
|
||||
with:
|
||||
files_from_source_file: |
|
||||
test/changed-files-list.txt
|
||||
|
||||
- name: Use a source file or list of file(s) to populate to files input and optionally specify more files.
|
||||
id: changed-files-specific-source-file-and-specify-files
|
||||
uses: tj-actions/changed-files@v11.3
|
||||
uses: tj-actions/changed-files@v11.4
|
||||
with:
|
||||
files_from_source_file: |
|
||||
test/changed-files-list.txt
|
||||
@@ -202,13 +202,13 @@ jobs:
|
||||
|
||||
- name: Use a different commit SHA
|
||||
id: changed-files-custom-sha
|
||||
uses: tj-actions/changed-files@v11.3
|
||||
uses: tj-actions/changed-files@v11.4
|
||||
with:
|
||||
sha: ${{ github.event.pull_request.head.sha }}
|
||||
|
||||
- name: Use a different base SHA
|
||||
id: changed-files-custom-base-sha
|
||||
uses: tj-actions/changed-files@v11.3
|
||||
uses: tj-actions/changed-files@v11.4
|
||||
with:
|
||||
base_sha: "2096ed0"
|
||||
|
||||
@@ -220,7 +220,7 @@ jobs:
|
||||
|
||||
- name: Run changed-files with defaults on the dir1
|
||||
id: changed-files-for-dir1
|
||||
uses: tj-actions/changed-files@v11.3
|
||||
uses: tj-actions/changed-files@v11.4
|
||||
with:
|
||||
path: dir1
|
||||
|
||||
@@ -229,6 +229,13 @@ jobs:
|
||||
for file in ${{ steps.changed-files-for-dir1.outputs.added_files }}; do
|
||||
echo "$file was added"
|
||||
done
|
||||
|
||||
- name: Run changed-files with since_last_remote_commit set to true
|
||||
id: changed-files-since-last-remote-commit
|
||||
uses: tj-actions/changed-files@v11.4
|
||||
with:
|
||||
since_last_remote_commit: 'true'
|
||||
|
||||
```
|
||||
|
||||
### Running [pre-commit](https://pre-commit.com/) on all modified files
|
||||
@@ -242,7 +249,7 @@ jobs:
|
||||
|
||||
- name: Get changed files
|
||||
id: changed-files
|
||||
uses: tj-actions/changed-files@v11.3
|
||||
uses: tj-actions/changed-files@v11.4
|
||||
|
||||
- name: Pre-commit
|
||||
uses: pre-commit/action@v2.0.0
|
||||
|
||||
@@ -97,7 +97,7 @@ runs:
|
||||
- run: |
|
||||
if [[ -n "${{ inputs.base_sha }}" ]]; then
|
||||
echo "::set-output name=base_sha::${{ inputs.base_sha }}"
|
||||
elif [[ "${{ github.event_name }}" == "push" && -z "${{ inputs.base_sha }}" && "${{ inputs.since_last_remote_commit }}" == "true" ]]; then
|
||||
elif [[ "${{ inputs.since_last_remote_commit }}" == "true" && -z "${{ inputs.base_sha }}" ]]; then
|
||||
echo "::set-output name=base_sha::${{ github.event.before }}"
|
||||
fi
|
||||
id: base-sha
|
||||
|
||||
Reference in New Issue
Block a user