Compare commits
21 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2a771ad30d | ||
|
|
11048977f0 | ||
|
|
b5198a4764 | ||
|
|
75933dc40b | ||
|
|
dc688ad0b2 | ||
|
|
5cab6c42e2 | ||
|
|
cc5b16fc9d | ||
|
|
ba01a24d10 | ||
|
|
a48d12ad38 | ||
|
|
dfe8a2779d | ||
|
|
2c0d12b627 | ||
|
|
3a01bb540d | ||
|
|
fba57fd3c6 | ||
|
|
7abdbc94e9 | ||
|
|
4f76fe6a8e | ||
|
|
1d1f2dec19 | ||
|
|
01fb130d1e | ||
|
|
031c7ba276 | ||
|
|
304c203f25 | ||
|
|
2e02d49f78 | ||
|
|
677631125b |
1
.github/ISSUE_TEMPLATE/bug_report.yaml
vendored
1
.github/ISSUE_TEMPLATE/bug_report.yaml
vendored
@@ -41,6 +41,7 @@ body:
|
||||
label: What OS are you seeing the problem on?
|
||||
multiple: true
|
||||
options:
|
||||
- all
|
||||
- ubuntu-latest or ubuntu-20.04
|
||||
- ubuntu-18.04
|
||||
- macos-latest or macos-10.15
|
||||
|
||||
49
.github/workflows/codacy-analysis.yml
vendored
Normal file
49
.github/workflows/codacy-analysis.yml
vendored
Normal file
@@ -0,0 +1,49 @@
|
||||
# This workflow checks out code, performs a Codacy security scan
|
||||
# and integrates the results with the
|
||||
# GitHub Advanced Security code scanning feature. For more information on
|
||||
# the Codacy security scan action usage and parameters, see
|
||||
# https://github.com/codacy/codacy-analysis-cli-action.
|
||||
# For more information on Codacy Analysis CLI in general, see
|
||||
# https://github.com/codacy/codacy-analysis-cli.
|
||||
|
||||
name: Codacy Security Scan
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ main ]
|
||||
pull_request:
|
||||
# The branches below must be a subset of the branches above
|
||||
branches: [ main ]
|
||||
schedule:
|
||||
- cron: '15 16 * * 2'
|
||||
|
||||
jobs:
|
||||
codacy-security-scan:
|
||||
name: Codacy Security Scan
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
# Checkout the repository to the GitHub Actions runner
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v2
|
||||
|
||||
# Execute Codacy Analysis CLI and generate a SARIF output with the security issues identified during the analysis
|
||||
- name: Run Codacy Analysis CLI
|
||||
uses: codacy/codacy-analysis-cli-action@4.0.0
|
||||
with:
|
||||
# Check https://github.com/codacy/codacy-analysis-cli#project-token to get your project token from your Codacy repository
|
||||
# You can also omit the token and run the tools that support default configurations
|
||||
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}
|
||||
verbose: true
|
||||
output: results.sarif
|
||||
format: sarif
|
||||
# Adjust severity of non-security issues
|
||||
gh-code-scanning-compat: true
|
||||
# Force 0 exit code to allow SARIF file generation
|
||||
# This will handover control about PR rejection to the GitHub side
|
||||
max-allowed-issues: 2147483647
|
||||
|
||||
# Upload the SARIF file generated in the previous step
|
||||
- name: Upload SARIF results file
|
||||
uses: github/codeql-action/upload-sarif@v1
|
||||
with:
|
||||
sarif_file: results.sarif
|
||||
23
.github/workflows/test.yml
vendored
23
.github/workflows/test.yml
vendored
@@ -18,7 +18,7 @@ jobs:
|
||||
- name: Checkout to branch
|
||||
uses: actions/checkout@v2
|
||||
- name: shellcheck
|
||||
uses: reviewdog/action-shellcheck@v1.6
|
||||
uses: reviewdog/action-shellcheck@v1.7
|
||||
|
||||
test-no-head-sha:
|
||||
name: Test changed-files missing head sha
|
||||
@@ -108,6 +108,25 @@ jobs:
|
||||
echo "${{ toJSON(steps.changed-files-specific.outputs) }}"
|
||||
shell:
|
||||
bash
|
||||
- name: Run changed-files with specific files comma check duplicates
|
||||
id: changed-files-specific-duplicate-output
|
||||
uses: ./
|
||||
with:
|
||||
files: |
|
||||
entrypoint.sh
|
||||
*.sh
|
||||
- name: Verify all_changed_files files has no duplicates
|
||||
if: contains(steps.changed-files-specific-duplicate-output.outputs.all_modified_files, 'entrypoint.sh')
|
||||
run: |
|
||||
ALL_CHANGED_FILES=(${{ steps.changed-files-specific-duplicate-output.outputs.all_modified_files }})
|
||||
UNIQUE_ALL_CHANGED_FILES=$(echo "$ALL_CHANGED_FILES" | tr ' ' '\n' | sort -u | xargs)
|
||||
|
||||
if [[ "$ALL_CHANGED_FILES[@]" != "$UNIQUE_ALL_CHANGED_FILES[@]" ]]; then
|
||||
echo "Duplicate output: Expected "$UNIQUE_ALL_CHANGED_FILES" got $ALL_CHANGED_FILES"
|
||||
exit 1
|
||||
fi
|
||||
shell:
|
||||
bash
|
||||
- name: Run changed-files with specific files comma separator
|
||||
id: changed-files-specific-comma
|
||||
uses: ./
|
||||
@@ -181,7 +200,7 @@ jobs:
|
||||
bash
|
||||
- name: Get branch name
|
||||
id: branch-name
|
||||
uses: tj-actions/branch-names@v4.5
|
||||
uses: tj-actions/branch-names@v4.8
|
||||
- uses: nrwl/last-successful-commit-action@v1
|
||||
id: last_successful_commit
|
||||
with:
|
||||
|
||||
76
HISTORY.md
76
HISTORY.md
@@ -1,5 +1,65 @@
|
||||
# Changelog
|
||||
|
||||
## [Unreleased](https://github.com/tj-actions/changed-files/tree/HEAD)
|
||||
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v9.2...HEAD)
|
||||
|
||||
**Fixed bugs:**
|
||||
|
||||
- \[BUG\] Dedupe the output list of changed files [\#151](https://github.com/tj-actions/changed-files/issues/151)
|
||||
|
||||
## [v9.2](https://github.com/tj-actions/changed-files/tree/v9.2) (2021-08-06)
|
||||
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v9.1...v9.2)
|
||||
|
||||
**Closed issues:**
|
||||
|
||||
- Dependency Dashboard [\#27](https://github.com/tj-actions/changed-files/issues/27)
|
||||
|
||||
**Merged pull requests:**
|
||||
|
||||
- Dedupe output file names. [\#153](https://github.com/tj-actions/changed-files/pull/153) ([jackton1](https://github.com/jackton1))
|
||||
- Update tj-actions/branch-names action to v4.8 [\#152](https://github.com/tj-actions/changed-files/pull/152) ([renovate[bot]](https://github.com/apps/renovate))
|
||||
- Upgraded to v9.1 [\#150](https://github.com/tj-actions/changed-files/pull/150) ([jackton1](https://github.com/jackton1))
|
||||
|
||||
## [v9.1](https://github.com/tj-actions/changed-files/tree/v9.1) (2021-07-30)
|
||||
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v9...v9.1)
|
||||
|
||||
**Implemented enhancements:**
|
||||
|
||||
- \[Feature\] any\_changed doesn't capture changes due to deleting files [\#148](https://github.com/tj-actions/changed-files/issues/148)
|
||||
|
||||
**Merged pull requests:**
|
||||
|
||||
- Detect deleted files via any\_changed output [\#149](https://github.com/tj-actions/changed-files/pull/149) ([jackton1](https://github.com/jackton1))
|
||||
- Update reviewdog/action-shellcheck action to v1.7 [\#147](https://github.com/tj-actions/changed-files/pull/147) ([renovate[bot]](https://github.com/apps/renovate))
|
||||
- Upgraded to v9 [\#146](https://github.com/tj-actions/changed-files/pull/146) ([jackton1](https://github.com/jackton1))
|
||||
|
||||
## [v9](https://github.com/tj-actions/changed-files/tree/v9) (2021-07-24)
|
||||
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v8.9...v9)
|
||||
|
||||
**Fixed bugs:**
|
||||
|
||||
- \[BUG\] \<any\_changed doesn't capture changes due to renaming files\> [\#144](https://github.com/tj-actions/changed-files/issues/144)
|
||||
|
||||
**Merged pull requests:**
|
||||
|
||||
- Update `any_changed` to include renamed files. [\#145](https://github.com/tj-actions/changed-files/pull/145) ([jackton1](https://github.com/jackton1))
|
||||
- Update codacy/codacy-analysis-cli-action action to v4 [\#143](https://github.com/tj-actions/changed-files/pull/143) ([renovate[bot]](https://github.com/apps/renovate))
|
||||
- Update codacy/codacy-analysis-cli-action action to v3 [\#142](https://github.com/tj-actions/changed-files/pull/142) ([renovate[bot]](https://github.com/apps/renovate))
|
||||
- Upgraded to v8.9 [\#140](https://github.com/tj-actions/changed-files/pull/140) ([jackton1](https://github.com/jackton1))
|
||||
|
||||
## [v8.9](https://github.com/tj-actions/changed-files/tree/v8.9) (2021-07-18)
|
||||
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v8.8...v8.9)
|
||||
|
||||
**Merged pull requests:**
|
||||
|
||||
- Updated README.md [\#139](https://github.com/tj-actions/changed-files/pull/139) ([jackton1](https://github.com/jackton1))
|
||||
- Upgraded to v8.8 [\#138](https://github.com/tj-actions/changed-files/pull/138) ([jackton1](https://github.com/jackton1))
|
||||
|
||||
## [v8.8](https://github.com/tj-actions/changed-files/tree/v8.8) (2021-07-17)
|
||||
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v8.7...v8.8)
|
||||
@@ -59,10 +119,6 @@
|
||||
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v8.3...v8.4)
|
||||
|
||||
**Closed issues:**
|
||||
|
||||
- Dependency Dashboard [\#27](https://github.com/tj-actions/changed-files/issues/27)
|
||||
|
||||
**Merged pull requests:**
|
||||
|
||||
- Update reviewdog/action-shellcheck action to v1.6 [\#118](https://github.com/tj-actions/changed-files/pull/118) ([renovate[bot]](https://github.com/apps/renovate))
|
||||
@@ -126,7 +182,7 @@
|
||||
|
||||
## [v7](https://github.com/tj-actions/changed-files/tree/v7) (2021-06-09)
|
||||
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v6.3...v7)
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v6...v7)
|
||||
|
||||
**Closed issues:**
|
||||
|
||||
@@ -142,13 +198,13 @@
|
||||
- Update tj-actions/sync-release-version action to v8.7 [\#86](https://github.com/tj-actions/changed-files/pull/86) ([renovate[bot]](https://github.com/apps/renovate))
|
||||
- Upgraded to v6.3 [\#85](https://github.com/tj-actions/changed-files/pull/85) ([jackton1](https://github.com/jackton1))
|
||||
|
||||
## [v6.3](https://github.com/tj-actions/changed-files/tree/v6.3) (2021-05-26)
|
||||
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v6...v6.3)
|
||||
|
||||
## [v6](https://github.com/tj-actions/changed-files/tree/v6) (2021-05-26)
|
||||
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v6.2...v6)
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v6.3...v6)
|
||||
|
||||
## [v6.3](https://github.com/tj-actions/changed-files/tree/v6.3) (2021-05-26)
|
||||
|
||||
[Full Changelog](https://github.com/tj-actions/changed-files/compare/v6.2...v6.3)
|
||||
|
||||
**Merged pull requests:**
|
||||
|
||||
|
||||
33
README.md
33
README.md
@@ -12,6 +12,7 @@ Retrieve all changed files relative to the default branch (`pull_request*` based
|
||||
|
||||
## Features
|
||||
|
||||
* Easy to debug.
|
||||
* Boolean output indicating that certain files have been modified.
|
||||
* List all files that have changed.
|
||||
* Between the current pull request branch and the default branch.
|
||||
@@ -55,7 +56,7 @@ jobs:
|
||||
|
||||
- name: Get changed files
|
||||
id: changed-files
|
||||
uses: tj-actions/changed-files@v8.8
|
||||
uses: tj-actions/changed-files@v9.2
|
||||
|
||||
- name: List all modified files
|
||||
run: |
|
||||
@@ -79,10 +80,10 @@ jobs:
|
||||
|
||||
| Output | type | example | description |
|
||||
|:--------------------:|:------------:|:----------------------------------:|:----------------------------------------:|
|
||||
| any_changed | `string` | `true` OR `false` | Returns `true` when any of the filenames provided using the `files` input has changed |
|
||||
| only_changed | `string` | `true` OR `false` | Returns `true` when only files provided using the `files` input have changed. |
|
||||
| any_changed | `string` | `true` OR `false` | Returns `true` when any <br /> of the filenames provided using <br /> the `files` input has changed (ACMDR) |
|
||||
| only_changed | `string` | `true` OR `false` | Returns `true` when only <br /> files provided using <br /> the `files` input have changed. |
|
||||
| other_changed_files | `string` | `'new.txt path/to/file.png ...'` | Select all modified files <br/> not listed in the files input <br /> i.e. *a combination of all added, <br /> copied and modified files (ACM).* |
|
||||
| all_modified_files | `string` | `'new.txt path/to/file.png ...'` | Select all modified files <br /> i.e. *a combination of all added, <br />copied and modified files (ACM).* |
|
||||
| all_modified_files | `string` | `'new.txt path/to/file.png ...'` | Select all modified files <br /> i.e. *a combination of all added, <br />copied, modified and renamed files (ACMR).* |
|
||||
| all_changed_files | `string` | `'new.txt path/to/file.png ...'` | Select all paths (\*) <br /> i.e. *a combination of all options below.* |
|
||||
| added_files | `string` | `'new.txt path/to/file.png ...'` | Select only files that are Added (A) |
|
||||
| copied_files | `string` | `'new.txt path/to/file.png ...'` | Select only files that are Copied (C) |
|
||||
@@ -113,11 +114,11 @@ jobs:
|
||||
|
||||
- name: Get changed files using defaults
|
||||
id: changed-files
|
||||
uses: tj-actions/changed-files@v8.8
|
||||
uses: tj-actions/changed-files@v9.2
|
||||
|
||||
- name: Get changed files using a comma separator
|
||||
id: changed-files-comma
|
||||
uses: tj-actions/changed-files@v8.8
|
||||
uses: tj-actions/changed-files@v9.2
|
||||
with:
|
||||
separator: ","
|
||||
|
||||
@@ -139,13 +140,14 @@ jobs:
|
||||
|
||||
- name: Get specific changed files
|
||||
id: changed-files-specific
|
||||
uses: tj-actions/changed-files@v8.8
|
||||
uses: tj-actions/changed-files@v9.2
|
||||
with:
|
||||
files: |
|
||||
my-file.txt
|
||||
test.txt
|
||||
new.txt
|
||||
test_directory
|
||||
*.sh
|
||||
.(png|jpeg)$
|
||||
.(sql)$
|
||||
^(mynewfile|custom)
|
||||
@@ -154,17 +156,22 @@ jobs:
|
||||
if: steps.changed-files-specific.outputs.any_changed == 'true'
|
||||
run: |
|
||||
echo "One or more files listed above has changed."
|
||||
|
||||
- name: Run step if only the files listed above change
|
||||
if: steps.changed-files-specific.outputs.only_changed == 'true'
|
||||
run: |
|
||||
echo "Only files listed above have changed."
|
||||
|
||||
- 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@v8.8
|
||||
uses: tj-actions/changed-files@v9.2
|
||||
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@v8.8
|
||||
uses: tj-actions/changed-files@v9.2
|
||||
with:
|
||||
files_from_source_file: |
|
||||
test/changed-files-list.txt
|
||||
@@ -173,13 +180,13 @@ jobs:
|
||||
|
||||
- name: Use a different commit SHA
|
||||
id: changed-files-custom-sha
|
||||
uses: tj-actions/changed-files@v8.8
|
||||
uses: tj-actions/changed-files@v9.2
|
||||
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@v8.8
|
||||
uses: tj-actions/changed-files@v9.2
|
||||
with:
|
||||
base_sha: "2096ed0"
|
||||
|
||||
@@ -196,7 +203,7 @@ jobs:
|
||||
|
||||
- name: Get changed files
|
||||
id: changed-files
|
||||
uses: tj-actions/changed-files@v8.8
|
||||
uses: tj-actions/changed-files@v9.2
|
||||
|
||||
- name: Pre-commit
|
||||
uses: pre-commit/action@v2.0.0
|
||||
@@ -205,8 +212,6 @@ jobs:
|
||||
token: ${{ secrets.github_token }}
|
||||
```
|
||||
|
||||
## Example
|
||||
|
||||

|
||||
|
||||

|
||||
|
||||
@@ -64,7 +64,7 @@ if [[ -z "$UNIQUE_FILES" ]]; then
|
||||
UNMERGED=$(git diff --diff-filter=U --name-only "$PREVIOUS_SHA" "$CURRENT_SHA" | tr "\n" "$INPUT_SEPARATOR" | sed -E "s/($INPUT_SEPARATOR)$//")
|
||||
UNKNOWN=$(git diff --diff-filter=X --name-only "$PREVIOUS_SHA" "$CURRENT_SHA" | tr "\n" "$INPUT_SEPARATOR" | sed -E "s/($INPUT_SEPARATOR)$//")
|
||||
ALL_CHANGED=$(git diff --diff-filter="*ACDMRTUX" --name-only "$PREVIOUS_SHA" "$CURRENT_SHA" | tr "\n" "$INPUT_SEPARATOR" | sed -E "s/($INPUT_SEPARATOR)$//")
|
||||
ALL_MODIFIED_FILES=$(git diff --diff-filter="ACM" --name-only "$PREVIOUS_SHA" "$CURRENT_SHA" | tr "\n" "$INPUT_SEPARATOR" | sed -E "s/($INPUT_SEPARATOR)$//")
|
||||
ALL_MODIFIED_FILES=$(git diff --diff-filter="ACMR" --name-only "$PREVIOUS_SHA" "$CURRENT_SHA" | tr "\n" "$INPUT_SEPARATOR" | sed -E "s/($INPUT_SEPARATOR)$//")
|
||||
else
|
||||
ADDED_ARRAY=()
|
||||
COPIED_ARRAY=()
|
||||
@@ -100,29 +100,29 @@ else
|
||||
# shellcheck disable=SC2207
|
||||
ALL_CHANGED_ARRAY+=($(git diff --diff-filter="*ACDMRTUX" --name-only "$PREVIOUS_SHA" "$CURRENT_SHA" | grep -E "(${path})" | xargs || true))
|
||||
# shellcheck disable=SC2207
|
||||
ALL_MODIFIED_FILES_ARRAY+=($(git diff --diff-filter="ACM" --name-only "$PREVIOUS_SHA" "$CURRENT_SHA" | grep -E "(${path})" | xargs || true))
|
||||
ALL_MODIFIED_FILES_ARRAY+=($(git diff --diff-filter="ACMR" --name-only "$PREVIOUS_SHA" "$CURRENT_SHA" | grep -E "(${path})" | xargs || true))
|
||||
done
|
||||
|
||||
# shellcheck disable=SC2001
|
||||
ADDED=$(echo "${ADDED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
|
||||
ADDED=$(echo "${ADDED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g' | tr ' ' '\n' | sort -u | xargs)
|
||||
# shellcheck disable=SC2001
|
||||
COPIED=$(echo "${COPIED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
|
||||
COPIED=$(echo "${COPIED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g' | tr ' ' '\n' | sort -u | xargs)
|
||||
# shellcheck disable=SC2001
|
||||
DELETED=$(echo "${DELETED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
|
||||
DELETED=$(echo "${DELETED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g' | tr ' ' '\n' | sort -u | xargs)
|
||||
# shellcheck disable=SC2001
|
||||
MODIFIED=$(echo "${MODIFIED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
|
||||
MODIFIED=$(echo "${MODIFIED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g' | tr ' ' '\n' | sort -u | xargs)
|
||||
# shellcheck disable=SC2001
|
||||
RENAMED=$(echo "${RENAMED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
|
||||
RENAMED=$(echo "${RENAMED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g' | tr ' ' '\n' | sort -u | xargs)
|
||||
# shellcheck disable=SC2001
|
||||
TYPE_CHANGED=$(echo "${TYPE_CHANGED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
|
||||
TYPE_CHANGED=$(echo "${TYPE_CHANGED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g' | tr ' ' '\n' | sort -u | xargs)
|
||||
# shellcheck disable=SC2001
|
||||
UNMERGED=$(echo "${UNMERGED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
|
||||
UNMERGED=$(echo "${UNMERGED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g' | tr ' ' '\n' | sort -u | xargs)
|
||||
# shellcheck disable=SC2001
|
||||
UNKNOWN=$(echo "${UNKNOWN_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
|
||||
UNKNOWN=$(echo "${UNKNOWN_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g' | tr ' ' '\n' | sort -u | xargs)
|
||||
# shellcheck disable=SC2001
|
||||
ALL_CHANGED=$(echo "${ALL_CHANGED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
|
||||
ALL_CHANGED=$(echo "${ALL_CHANGED_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g' | tr ' ' '\n' | sort -u | xargs)
|
||||
# shellcheck disable=SC2001
|
||||
ALL_MODIFIED_FILES=$(echo "${ALL_MODIFIED_FILES_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g')
|
||||
ALL_MODIFIED_FILES=$(echo "${ALL_MODIFIED_FILES_ARRAY[*]}" | sed 's/ */'"$INPUT_SEPARATOR"'/g' | tr ' ' '\n' | sort -u | xargs)
|
||||
fi
|
||||
|
||||
echo "Added files: $ADDED"
|
||||
@@ -139,7 +139,7 @@ echo "All modified files: $ALL_MODIFIED_FILES"
|
||||
if [[ -n "$UNIQUE_FILES" ]]; then
|
||||
# shellcheck disable=SC2001
|
||||
ALL_INPUT_FILES=$(echo "$UNIQUE_FILES" | tr "\n" " " | xargs)
|
||||
ALL_OTHER_CHANGED_FILES=$(git diff --diff-filter="ACM" --name-only "$PREVIOUS_SHA" "$CURRENT_SHA")
|
||||
ALL_OTHER_CHANGED_FILES=$(git diff --diff-filter="ACMR" --name-only "$PREVIOUS_SHA" "$CURRENT_SHA")
|
||||
|
||||
OTHER_CHANGED_FILES=$(echo "${ALL_OTHER_CHANGED_FILES[@]}" "${ALL_MODIFIED_FILES[@]}" | tr ' ' '\n' | sort | uniq -u | tr "\n" " " | xargs)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user