Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: tj-actions/changed-files
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v44.5.7
Choose a base ref
...
head repository: tj-actions/changed-files
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v45.0.0
Choose a head ref

Commits on Jul 31, 2024

  1. chore(deps): update dependency @types/node to v22.0.1

    renovate[bot] committed Jul 31, 2024

    Verified

    This commit was signed with the committer’s verified signature.
    benjamn Ben Newman
    Copy the full SHA
    03d95b0 View commit details
  2. Upgraded to v44.5.7 (#2218)

    Co-authored-by: jackton1 <17484350+jackton1@users.noreply.github.com>
    tj-actions-bot and jackton1 authored Jul 31, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    7103800 View commit details

Commits on Aug 1, 2024

  1. chore(deps): update dependency ts-jest to v29.2.4

    renovate[bot] committed Aug 1, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    8ae850f View commit details

Commits on Aug 2, 2024

  1. chore(deps): update dependency @types/node to v22.0.3

    renovate[bot] committed Aug 2, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    99b60a2 View commit details
  2. chore(deps): update dependency @types/node to v22.1.0

    renovate[bot] committed Aug 2, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    6b79c79 View commit details

Commits on Aug 4, 2024

  1. chore(deps): update dependency eslint-plugin-jest to v28.7.0

    renovate[bot] committed Aug 4, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    9d768c3 View commit details

Commits on Aug 7, 2024

  1. chore(deps): update dependency eslint-plugin-jest to v28.8.0

    renovate[bot] committed Aug 7, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    ed00b69 View commit details

Commits on Aug 9, 2024

  1. chore(deps): update dependency @types/node to v22.2.0

    renovate[bot] committed Aug 9, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    950331d View commit details

Commits on Aug 14, 2024

  1. chore(deps): update dependency @types/node to v22.3.0

    renovate[bot] committed Aug 14, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    87d8f94 View commit details

Commits on Aug 16, 2024

  1. chore(deps): update dependency @types/node to v22.4.0

    renovate[bot] committed Aug 16, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    50693d8 View commit details
  2. fix(deps): update dependency @octokit/rest to v21.0.2

    renovate[bot] committed Aug 16, 2024

    Partially verified

    This commit is signed with the committer’s verified signature.
    benjamn’s contribution has been verified via GPG key.
    We cannot verify signatures from co-authors, and some of the co-authors attributed to this commit require their commits to be signed.
    Copy the full SHA
    3ea85a1 View commit details

Commits on Aug 18, 2024

  1. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    9b7ba7b View commit details
  2. Update tsconfig.json

    jackton1 authored and renovate[bot] committed Aug 18, 2024

    Verified

    This commit was signed with the committer’s verified signature.
    benjamn Ben Newman
    Copy the full SHA
    88201be View commit details
  3. Added missing changes and modified dist assets.

    actions-user authored and renovate[bot] committed Aug 18, 2024
    Copy the full SHA
    598b721 View commit details

Commits on Aug 19, 2024

  1. chore(deps): update dependency @types/node to v22.4.1

    renovate[bot] committed Aug 19, 2024
    Copy the full SHA
    257f12c View commit details

Commits on Aug 21, 2024

  1. chore(deps): update dependency @types/node to v22.4.2

    renovate[bot] committed Aug 21, 2024
    Copy the full SHA
    25b2562 View commit details
  2. fix: remove unsupported input (#2238)

    jackton1 authored Aug 21, 2024
    Copy the full SHA
    525aabb View commit details
  3. chore: conditionally skip certain test for foked prs (#2240)

    Co-authored-by: tj-actions[bot] <109116665+tj-actions-bot@users.noreply.github.com>
    jackton1 and tj-actions-bot authored Aug 21, 2024
    Copy the full SHA
    46a4c02 View commit details
  4. chore: debug env vars (#2241)

    jackton1 authored Aug 21, 2024
    Copy the full SHA
    246859d View commit details
  5. fix: update test skip logic to use custom env (#2242)

    jackton1 authored Aug 21, 2024
    Copy the full SHA
    b4c0974 View commit details
  6. Renamed Files decomposed into Deleted: previous_filename and Added:fi…

    …lename (#2236)
    
    Co-authored-by: Tonye Jack <jtonye@ymail.com>
    Whadup and jackton1 authored Aug 21, 2024
    Copy the full SHA
    f8034fb View commit details
  7. docs: add Whadup as a contributor for code (#2239)

    Co-authored-by: allcontributors[bot] <46447321+allcontributors[bot]@users.noreply.github.com>
    allcontributors[bot] authored Aug 21, 2024
    Copy the full SHA
    94b94fe View commit details
  8. Updated README.md (#2243)

    Co-authored-by: jackton1 <17484350+jackton1@users.noreply.github.com>
    Co-authored-by: GitHub Action <action@github.com>
    3 people authored Aug 21, 2024
    Copy the full SHA
    40853de View commit details
Showing with 807 additions and 830 deletions.
  1. +9 −0 .all-contributorsrc
  2. +2 −1 .github/workflows/test.yml
  3. +29 −0 HISTORY.md
  4. +2 −1 README.md
  5. +387 −491 dist/index.js
  6. +1 −1 dist/index.js.map
  7. +1 −1 package.json
  8. +11 −2 src/__tests__/utils.test.ts
  9. +1 −1 src/changedFiles.ts
  10. +1 −1 tsconfig.json
  11. +363 −331 yarn.lock
9 changes: 9 additions & 0 deletions .all-contributorsrc
Original file line number Diff line number Diff line change
@@ -245,6 +245,15 @@
"code",
"bug"
]
},
{
"login": "Whadup",
"name": "Lukas Pfahler",
"avatar_url": "https://avatars.githubusercontent.com/u/2308119?v=4",
"profile": "https://lukaspfahler.de",
"contributions": [
"code"
]
}
],
"contributorsPerLine": 7,
3 changes: 2 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -65,11 +65,12 @@ jobs:
with:
token: ${{ secrets.PAT_TOKEN }}
config_path: ".eslintrc.json"
ignore_path: ".eslintignore"

- name: Run build and test
run: |
yarn all
env:
GITHUB_EVENT_PULL_REQUEST_HEAD_REPO_FORK: ${{ github.event.pull_request.head.repo.fork }}

- name: Verify Changed files
uses: tj-actions/verify-changed-files@v20
29 changes: 29 additions & 0 deletions HISTORY.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,34 @@
# Changelog

# [44.5.7](https://github.com/tj-actions/changed-files/compare/v44.5.6...v44.5.7) - (2024-07-30)

## <!-- 1 -->🐛 Bug Fixes

- **deps:** Update dependency @stdlib/utils-convert-path to v0.2.2 ([e4fe134](https://github.com/tj-actions/changed-files/commit/e4fe134b735e3c67d244091a6c505cbb39b32212)) - (renovate[bot])
- Error with pull_request closed test ([#2211](https://github.com/tj-actions/changed-files/issues/2211)) ([f5a7145](https://github.com/tj-actions/changed-files/commit/f5a7145f2ba7e6d42d799f0270017afc09189f64)) - (Tonye Jack)
- **deps:** Update dependency yaml to v2.5.0 ([28fd03b](https://github.com/tj-actions/changed-files/commit/28fd03b28d647c18884fa609756e9aa323da9598)) - (renovate[bot])

## <!-- 16 -->➕ Add

- Added missing changes and modified dist assets.
([a77ecbc](https://github.com/tj-actions/changed-files/commit/a77ecbc238d92fd078cf5deee43b895a3a5b3fef)) - (GitHub Action)
- Added missing changes and modified dist assets.
([1047179](https://github.com/tj-actions/changed-files/commit/10471793b2c8356c90f4ddf302561e23d57582ac)) - (GitHub Action)

## <!-- 7 -->⚙️ Miscellaneous Tasks

- **deps-dev:** Bump @types/node from 20.14.13 to 22.0.0 ([#2215](https://github.com/tj-actions/changed-files/issues/2215)) ([c65cd88](https://github.com/tj-actions/changed-files/commit/c65cd883420fd2eb864698a825fc4162dd94482c)) - (dependabot[bot])
- **deps:** Update typescript-eslint monorepo to v7.18.0 ([9f928e3](https://github.com/tj-actions/changed-files/commit/9f928e3005748ed5c45dcdb97c101a4547f612d0)) - (renovate[bot])
- **deps:** Update dependency @types/node to v20.14.13 ([fb1b47b](https://github.com/tj-actions/changed-files/commit/fb1b47b72779e62a69dc98934f3e07e01eb78735)) - (renovate[bot])
- **deps:** Update dependency @types/node to v20.14.12 ([4db04c7](https://github.com/tj-actions/changed-files/commit/4db04c76fac5b37cc0308020af9c651f2447a026)) - (renovate[bot])
- **deps:** Update typescript-eslint monorepo to v7.17.0 ([f79274f](https://github.com/tj-actions/changed-files/commit/f79274f27befa7e1bf6d5eb1c4964c0f65cea226)) - (renovate[bot])

## <!-- 9 -->⬆️ Upgrades

- Upgraded to v44.5.6 ([#2204](https://github.com/tj-actions/changed-files/issues/2204))

Co-authored-by: jackton1 <17484350+jackton1@users.noreply.github.com> ([f1d2215](https://github.com/tj-actions/changed-files/commit/f1d2215d5d3ce1f57b3ad38a3db65d0e2cfbdb38)) - (tj-actions[bot])

# [44.5.6](https://github.com/tj-actions/changed-files/compare/v44.5.5...v44.5.6) - (2024-07-18)

## <!-- 1 -->🐛 Bug Fixes
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -9,7 +9,7 @@

<!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section -->

[![All Contributors](https://img.shields.io/badge/all_contributors-26-orange.svg?style=flat-square)](#contributors-)
[![All Contributors](https://img.shields.io/badge/all_contributors-27-orange.svg?style=flat-square)](#contributors-)

<!-- ALL-CONTRIBUTORS-BADGE:END -->

@@ -1444,6 +1444,7 @@ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/d
<td align="center" valign="top" width="14.28%"><a href="https://github.com/dan-hill2802"><img src="https://avatars.githubusercontent.com/u/5046322?v=4?s=100" width="100px;" alt="Daniel Hill"/><br /><sub><b>Daniel Hill</b></sub></a><br /><a href="https://github.com/tj-actions/changed-files/commits?author=dan-hill2802" title="Documentation">📖</a></td>
<td align="center" valign="top" width="14.28%"><a href="https://keisukeyamashita.com"><img src="https://avatars.githubusercontent.com/u/23056537?v=4?s=100" width="100px;" alt="KeisukeYamashita"/><br /><sub><b>KeisukeYamashita</b></sub></a><br /><a href="https://github.com/tj-actions/changed-files/commits?author=KeisukeYamashita" title="Documentation">📖</a></td>
<td align="center" valign="top" width="14.28%"><a href="https://github.com/codesculpture"><img src="https://avatars.githubusercontent.com/u/63452117?v=4?s=100" width="100px;" alt="Aravind"/><br /><sub><b>Aravind</b></sub></a><br /><a href="https://github.com/tj-actions/changed-files/commits?author=codesculpture" title="Code">💻</a> <a href="https://github.com/tj-actions/changed-files/issues?q=author%3Acodesculpture" title="Bug reports">🐛</a></td>
<td align="center" valign="top" width="14.28%"><a href="https://lukaspfahler.de"><img src="https://avatars.githubusercontent.com/u/2308119?v=4?s=100" width="100px;" alt="Lukas Pfahler"/><br /><sub><b>Lukas Pfahler</b></sub></a><br /><a href="https://github.com/tj-actions/changed-files/commits?author=Whadup" title="Code">💻</a></td>
</tr>
</tbody>
</table>
878 changes: 387 additions & 491 deletions dist/index.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@tj-actions/changed-files",
"version": "44.5.6",
"version": "44.5.7",
"description": "Github action to retrieve all (added, copied, modified, deleted, renamed, type changed, unmerged, unknown) files and directories.",
"main": "lib/main.js",
"publishConfig": {
13 changes: 11 additions & 2 deletions src/__tests__/utils.test.ts
Original file line number Diff line number Diff line change
@@ -659,8 +659,13 @@ describe('utils test', () => {
})
})
describe('getPreviousGitTag', () => {
// Check if the environment variable GITHUB_REPOSITORY_OWNER is 'tj-actions'
const shouldSkip = !!process.env.GITHUB_EVENT_PULL_REQUEST_HEAD_REPO_FORK
// Function returns the second-latest tag and its SHA
it('should return the second latest tag and its SHA when multiple tags are present', async () => {
if (shouldSkip) {
return
}
const result = await getPreviousGitTag({
cwd: '.',
tagsPattern: '*',
@@ -672,9 +677,11 @@ describe('utils test', () => {
sha: 'f0751de6af436d4e79016e2041cf6400e0833653'
})
})

// Tags are filtered by a specified pattern when 'tagsPattern' is provided
it('should filter tags by the specified pattern', async () => {
if (shouldSkip) {
return
}
const result = await getPreviousGitTag({
cwd: '.',
tagsPattern: 'v1.*',
@@ -686,9 +693,11 @@ describe('utils test', () => {
sha: 'f0751de6af436d4e79016e2041cf6400e0833653'
})
})

// Tags are excluded by a specified ignore pattern when 'tagsIgnorePattern' is provided
it('should exclude tags by the specified ignore pattern', async () => {
if (shouldSkip) {
return
}
const result = await getPreviousGitTag({
cwd: '.',
tagsPattern: '*',
2 changes: 1 addition & 1 deletion src/changedFiles.ts
Original file line number Diff line number Diff line change
@@ -484,7 +484,7 @@ export const getChangedFilesFromGithubAPI = async ({

if (changeType === ChangeTypeEnum.Renamed) {
if (inputs.outputRenamedFilesAsDeletedAndAdded) {
changedFiles[ChangeTypeEnum.Deleted].push(item.filename)
changedFiles[ChangeTypeEnum.Deleted].push(item.previous_filename || '')
changedFiles[ChangeTypeEnum.Added].push(item.filename)
} else {
changedFiles[ChangeTypeEnum.Renamed].push(item.filename)
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"compilerOptions": {
"target": "es6", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019' or 'ESNEXT'. */
"target": "ES2018", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019' or 'ESNEXT'. */
"module": "commonjs", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */
"outDir": "./lib", /* Redirect output structure to the directory. */
"rootDir": "./src", /* Specify the root directory of input files. Use to control the output directory structure with --outDir. */
694 changes: 363 additions & 331 deletions yarn.lock

Large diffs are not rendered by default.