Compare commits
10 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
991e8b3aae | ||
|
|
420a7792d0 | ||
|
|
e062ae86aa | ||
|
|
6326c61a70 | ||
|
|
eea929be22 | ||
|
|
9962dc418e | ||
|
|
77f03d2bb5 | ||
|
|
a236f54cc9 | ||
|
|
de6d1ed419 | ||
|
|
5345fb6b0e |
4
.github/workflows/test.yml
vendored
4
.github/workflows/test.yml
vendored
@@ -127,9 +127,9 @@ jobs:
|
|||||||
until: "2022-08-20"
|
until: "2022-08-20"
|
||||||
|
|
||||||
- name: Check output
|
- name: Check output
|
||||||
if: "!contains(steps.changed-files-until.outputs.all_changed_files, 'entrypoint.sh')"
|
if: "!contains(steps.changed-files-until.outputs.all_changed_files, 'README.md')"
|
||||||
run: |
|
run: |
|
||||||
echo "Invalid output: Expected to include (entrypoint.sh) got (${{ steps.changed-files-until.outputs.all_changed_files }})"
|
echo "Invalid output: Expected to include (README.md) got (${{ steps.changed-files-until.outputs.all_changed_files }})"
|
||||||
exit 1
|
exit 1
|
||||||
shell:
|
shell:
|
||||||
bash
|
bash
|
||||||
|
|||||||
36
HISTORY.md
36
HISTORY.md
@@ -1,12 +1,30 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
## [v34.3.0](https://github.com/tj-actions/changed-files/tree/v34.3.0) (2022-11-07)
|
## [v34.3.2](https://github.com/tj-actions/changed-files/tree/v34.3.2) (2022-11-07)
|
||||||
|
|
||||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v34...v34.3.0)
|
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v34.3.1...v34.3.2)
|
||||||
|
|
||||||
|
## [v34.3.1](https://github.com/tj-actions/changed-files/tree/v34.3.1) (2022-11-07)
|
||||||
|
|
||||||
|
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v34...v34.3.1)
|
||||||
|
|
||||||
## [v34](https://github.com/tj-actions/changed-files/tree/v34) (2022-11-07)
|
## [v34](https://github.com/tj-actions/changed-files/tree/v34) (2022-11-07)
|
||||||
|
|
||||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v34.2.2...v34)
|
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v34.3.0...v34)
|
||||||
|
|
||||||
|
**Fixed bugs:**
|
||||||
|
|
||||||
|
- \[BUG\] Similar commit hashes detected: previous sha: abc123 is equivalent to the current sha: abc123 on PR merge [\#778](https://github.com/tj-actions/changed-files/issues/778)
|
||||||
|
|
||||||
|
**Merged pull requests:**
|
||||||
|
|
||||||
|
- fix: similar commit hashes [\#780](https://github.com/tj-actions/changed-files/pull/780) ([jackton1](https://github.com/jackton1))
|
||||||
|
- chore: update readme [\#779](https://github.com/tj-actions/changed-files/pull/779) ([jackton1](https://github.com/jackton1))
|
||||||
|
- Upgraded to v34.3.0 [\#777](https://github.com/tj-actions/changed-files/pull/777) ([jackton1](https://github.com/jackton1))
|
||||||
|
|
||||||
|
## [v34.3.0](https://github.com/tj-actions/changed-files/tree/v34.3.0) (2022-11-07)
|
||||||
|
|
||||||
|
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v34.2.2...v34.3.0)
|
||||||
|
|
||||||
**Closed issues:**
|
**Closed issues:**
|
||||||
|
|
||||||
@@ -350,7 +368,7 @@
|
|||||||
|
|
||||||
## [v30](https://github.com/tj-actions/changed-files/tree/v30) (2022-09-24)
|
## [v30](https://github.com/tj-actions/changed-files/tree/v30) (2022-09-24)
|
||||||
|
|
||||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v29.0.9...v30)
|
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v29...v30)
|
||||||
|
|
||||||
**Fixed bugs:**
|
**Fixed bugs:**
|
||||||
|
|
||||||
@@ -366,13 +384,13 @@
|
|||||||
- chore\(deps\): update codacy/codacy-analysis-cli-action action to v4.2.0 [\#634](https://github.com/tj-actions/changed-files/pull/634) ([renovate[bot]](https://github.com/apps/renovate))
|
- chore\(deps\): update codacy/codacy-analysis-cli-action action to v4.2.0 [\#634](https://github.com/tj-actions/changed-files/pull/634) ([renovate[bot]](https://github.com/apps/renovate))
|
||||||
- Upgraded to v29.0.9 [\#633](https://github.com/tj-actions/changed-files/pull/633) ([jackton1](https://github.com/jackton1))
|
- Upgraded to v29.0.9 [\#633](https://github.com/tj-actions/changed-files/pull/633) ([jackton1](https://github.com/jackton1))
|
||||||
|
|
||||||
## [v29.0.9](https://github.com/tj-actions/changed-files/tree/v29.0.9) (2022-09-20)
|
|
||||||
|
|
||||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v29...v29.0.9)
|
|
||||||
|
|
||||||
## [v29](https://github.com/tj-actions/changed-files/tree/v29) (2022-09-20)
|
## [v29](https://github.com/tj-actions/changed-files/tree/v29) (2022-09-20)
|
||||||
|
|
||||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v29.0.8...v29)
|
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v29.0.9...v29)
|
||||||
|
|
||||||
|
## [v29.0.9](https://github.com/tj-actions/changed-files/tree/v29.0.9) (2022-09-20)
|
||||||
|
|
||||||
|
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v29.0.8...v29.0.9)
|
||||||
|
|
||||||
**Implemented enhancements:**
|
**Implemented enhancements:**
|
||||||
|
|
||||||
|
|||||||
@@ -52,9 +52,13 @@ Retrieve all changed files and directories relative to the target branch or the
|
|||||||
name: CI
|
name: CI
|
||||||
|
|
||||||
on:
|
on:
|
||||||
|
# Compare the preceeding commit of main -> to the current commit of the main branch.
|
||||||
|
# (Note: To compare changes between the last pushed commit to the remote main branch set `since_last_remote_commit: true`)
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- main
|
- main
|
||||||
|
# Compare the last commit of main -> to the current commit of a PR branch.
|
||||||
|
# (Note: To compare changes between the last pushed commit to the remote PR branch set `since_last_remote_commit: true`)
|
||||||
pull_request:
|
pull_request:
|
||||||
branches:
|
branches:
|
||||||
- main
|
- main
|
||||||
|
|||||||
@@ -179,7 +179,7 @@ runs:
|
|||||||
INPUT_FETCH_DEPTH: ${{ inputs.fetch_depth }}
|
INPUT_FETCH_DEPTH: ${{ inputs.fetch_depth }}
|
||||||
INPUT_SINCE_LAST_REMOTE_COMMIT: ${{ inputs.since_last_remote_commit }}
|
INPUT_SINCE_LAST_REMOTE_COMMIT: ${{ inputs.since_last_remote_commit }}
|
||||||
- name: Glob match
|
- name: Glob match
|
||||||
uses: tj-actions/glob@v15
|
uses: tj-actions/glob@v16
|
||||||
id: glob
|
id: glob
|
||||||
with:
|
with:
|
||||||
files: ${{ inputs.files }}
|
files: ${{ inputs.files }}
|
||||||
|
|||||||
13
diff-sha.sh
13
diff-sha.sh
@@ -45,8 +45,6 @@ fi
|
|||||||
|
|
||||||
if [[ -z $GITHUB_BASE_REF ]]; then
|
if [[ -z $GITHUB_BASE_REF ]]; then
|
||||||
echo "Running on a push event..."
|
echo "Running on a push event..."
|
||||||
TARGET_BRANCH=${GITHUB_REF/refs\/heads\//} && exit_status=$? || exit_status=$?
|
|
||||||
CURRENT_BRANCH=$TARGET_BRANCH && exit_status=$? || exit_status=$?
|
|
||||||
|
|
||||||
echo "::debug::Getting HEAD SHA..."
|
echo "::debug::Getting HEAD SHA..."
|
||||||
if [[ -n "$INPUT_UNTIL" ]]; then
|
if [[ -n "$INPUT_UNTIL" ]]; then
|
||||||
@@ -67,6 +65,9 @@ if [[ -z $GITHUB_BASE_REF ]]; then
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
TARGET_BRANCH=$(git name-rev --name-only "$CURRENT_SHA" 2>&1) && exit_status=$? || exit_status=$?
|
||||||
|
CURRENT_BRANCH=$TARGET_BRANCH && exit_status=$? || exit_status=$?
|
||||||
|
|
||||||
echo "::debug::Verifying the current commit SHA: $CURRENT_SHA"
|
echo "::debug::Verifying the current commit SHA: $CURRENT_SHA"
|
||||||
git rev-parse --quiet --verify "$CURRENT_SHA^{commit}" 1>/dev/null 2>&1 && exit_status=$? || exit_status=$?
|
git rev-parse --quiet --verify "$CURRENT_SHA^{commit}" 1>/dev/null 2>&1 && exit_status=$? || exit_status=$?
|
||||||
|
|
||||||
@@ -127,8 +128,6 @@ if [[ -z $GITHUB_BASE_REF ]]; then
|
|||||||
# shellcheck disable=SC2086
|
# shellcheck disable=SC2086
|
||||||
git fetch $EXTRA_ARGS -u --progress --deepen="$INPUT_FETCH_DEPTH"
|
git fetch $EXTRA_ARGS -u --progress --deepen="$INPUT_FETCH_DEPTH"
|
||||||
PREVIOUS_SHA=$INPUT_BASE_SHA
|
PREVIOUS_SHA=$INPUT_BASE_SHA
|
||||||
TARGET_BRANCH=$(git name-rev --name-only "$PREVIOUS_SHA" 2>&1) && exit_status=$? || exit_status=$?
|
|
||||||
CURRENT_BRANCH=$TARGET_BRANCH
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "::debug::Target branch $TARGET_BRANCH..."
|
echo "::debug::Target branch $TARGET_BRANCH..."
|
||||||
@@ -199,10 +198,10 @@ else
|
|||||||
|
|
||||||
if [[ -z $INPUT_BASE_SHA ]]; then
|
if [[ -z $INPUT_BASE_SHA ]]; then
|
||||||
if [[ "$INPUT_SINCE_LAST_REMOTE_COMMIT" == "true" ]]; then
|
if [[ "$INPUT_SINCE_LAST_REMOTE_COMMIT" == "true" ]]; then
|
||||||
PREVIOUS_SHA=""
|
PREVIOUS_SHA=$GITHUB_EVENT_BEFORE
|
||||||
|
|
||||||
if [[ "$GITHUB_EVENT_FORCED" == "false" || -z "$GITHUB_EVENT_FORCED" ]]; then
|
if ! git rev-parse --quiet --verify "$PREVIOUS_SHA^{commit}" 1>/dev/null 2>&1; then
|
||||||
PREVIOUS_SHA=$GITHUB_EVENT_BEFORE
|
PREVIOUS_SHA=$(git rev-list -n 1 "$TARGET_BRANCH" 2>&1) && exit_status=$? || exit_status=$?
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ -z "$PREVIOUS_SHA" || "$PREVIOUS_SHA" == "0000000000000000000000000000000000000000" ]]; then
|
if [[ -z "$PREVIOUS_SHA" || "$PREVIOUS_SHA" == "0000000000000000000000000000000000000000" ]]; then
|
||||||
|
|||||||
Reference in New Issue
Block a user