{"id":13623230,"url":"https://github.com/tj-actions/verify-changed-files","last_synced_at":"2025-04-08T09:07:20.627Z","repository":{"id":37500129,"uuid":"273291963","full_name":"tj-actions/verify-changed-files","owner":"tj-actions","description":":octocat: Github action to verify file changes that occur during the workflow execution.","archived":false,"fork":false,"pushed_at":"2025-03-23T11:48:19.000Z","size":620,"stargazers_count":176,"open_issues_count":0,"forks_count":24,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-01T08:39:53.852Z","etag":null,"topics":["actions","automation","change-detection","changed-file","detects-files","github","github-actions","release-automation","verify","workflow","workflow-execution","workflows"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tj-actions.png","metadata":{"files":{"readme":"README.md","changelog":"HISTORY.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":["jackton1"],"patreon":null,"open_collective":"tj-actions","ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":[]}},"created_at":"2020-06-18T16:48:11.000Z","updated_at":"2025-03-31T00:50:22.000Z","dependencies_parsed_at":"2024-03-02T02:38:05.257Z","dependency_job_id":"50355058-0684-46b8-8881-ecab4ff405e2","html_url":"https://github.com/tj-actions/verify-changed-files","commit_stats":{"total_commits":691,"total_committers":17,"mean_commits":40.64705882352941,"dds":0.492040520984081,"last_synced_commit":"21026c9e0e5b8c2ada1459acc4442be712292eb5"},"previous_names":[],"tags_count":79,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tj-actions%2Fverify-changed-files","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tj-actions%2Fverify-changed-files/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tj-actions%2Fverify-changed-files/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tj-actions%2Fverify-changed-files/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tj-actions","download_url":"https://codeload.github.com/tj-actions/verify-changed-files/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247714161,"owners_count":20983833,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["actions","automation","change-detection","changed-file","detects-files","github","github-actions","release-automation","verify","workflow","workflow-execution","workflows"],"created_at":"2024-08-01T21:01:29.379Z","updated_at":"2025-04-08T09:07:20.603Z","avatar_url":"https://github.com/tj-actions.png","language":"Shell","funding_links":["https://github.com/sponsors/jackton1","https://opencollective.com/tj-actions","https://www.buymeacoffee.com/jackton1"],"categories":["Shell"],"sub_categories":[],"readme":"[![Ubuntu](https://img.shields.io/badge/Ubuntu-E95420?style=for-the-badge\\\u0026logo=ubuntu\\\u0026logoColor=white)](https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idruns-on)\n[![Mac OS](https://img.shields.io/badge/mac%20os-000000?style=for-the-badge\\\u0026logo=macos\\\u0026logoColor=F0F0F0)](https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idruns-on)\n[![Windows](https://img.shields.io/badge/Windows-0078D6?style=for-the-badge\\\u0026logo=windows\\\u0026logoColor=white)](https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idruns-on)\n[![Public workflows that use this action.](https://img.shields.io/endpoint?style=for-the-badge\\\u0026url=https%3A%2F%2Fused-by.vercel.app%2Fapi%2Fgithub-actions%2Fused-by%3Faction%3Dtj-actions%2Fverify-changed-files%26badge%3Dtrue)](https://github.com/search?o=desc\\\u0026q=tj-actions+verify-changed-files+language%3AYAML\\\u0026s=\\\u0026type=Code)\n\n[![Codacy Badge](https://app.codacy.com/project/badge/Grade/ef128a4f001846f8a5a50316c8d3c5c3)](https://app.codacy.com/gh/tj-actions/verify-changed-files/dashboard?utm_source=gh\\\u0026utm_medium=referral\\\u0026utm_content=\\\u0026utm_campaign=Badge_grade)\n[![CI](https://github.com/tj-actions/verify-changed-files/workflows/CI/badge.svg)](https://github.com/tj-actions/verify-changed-files/actions?query=workflow%3ACI)\n[![Update release version.](https://github.com/tj-actions/verify-changed-files/workflows/Update%20release%20version./badge.svg)](https://github.com/tj-actions/verify-changed-files/actions?query=workflow%3A%22Update+release+version.%22)\n\n\u003c!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section --\u003e\n\n[![All Contributors](https://img.shields.io/badge/all_contributors-6-orange.svg?style=flat-square)](#contributors-)\n\n\u003c!-- ALL-CONTRIBUTORS-BADGE:END --\u003e\n\n# verify-changed-files\n\nVerify that certain files or directories did or did not change during the workflow execution.\n\n\u003e \\[!NOTE]\n\u003e\n\u003e *   This action only detects files that have pending uncommitted changes generated during the workflow execution, for running a specific step when a file changes in a pull request or based on a pushed commit\n\u003e\n\u003e     See: https://github.com/tj-actions/changed-files instead\n\n## Features\n\n*   Fast execution (0-2 seconds on average).\n*   Easy to debug.\n*   Scales to large repositories.\n*   Supports all platforms (Linux, MacOS, Windows).\n*   [GitHub-hosted runners](https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners) support\n*   [GitHub Enterprise Server](https://docs.github.com/en/enterprise-server@3.3/admin/github-actions/getting-started-with-github-actions-for-your-enterprise/getting-started-with-github-actions-for-github-enterprise-server) support.\n*   [self-hosted runners](https://docs.github.com/en/actions/hosting-your-own-runners/about-self-hosted-runners) support.\n*   Boolean output for detecting uncommitted changes.\n*   List all files that changed during the workflow execution.\n*   Detect changes to track and untracked files.\n*   Restrict change detection to a subset of files:\n    *   Using [Glob pattern](https://docs.github.com/en/actions/learn-github-actions/workflow-syntax-for-github-actions#filter-pattern-cheat-sheet) matching.\n        *   Supports Globstar.\n        *   Supports brace expansion.\n        *   Supports negation.\n\n## Usage\n\n```yaml\n...\n    steps:\n      - uses: actions/checkout@v4\n\n      - name: Change text file\n        run: |\n          echo \"Modified\" \u003e new.txt\n\n      - name: Change file in directory\n        run: |\n          echo \"Changed\" \u003e test_directory/new.txt\n\n      - name: Verify Changed files\n        uses: tj-actions/verify-changed-files@a1c6acee9df209257a246f2cc6ae8cb6581c1edf # v20\n        id: verify-changed-files\n        with:\n          files: |\n             *.txt\n             test_directory\n             action.yml\n             **/*.{jpeg,py}\n             !*.sql\n\n      - name: Run step only when any of the above files change.\n        if: steps.verify-changed-files.outputs.files_changed == 'true'\n        env:\n          CHANGED_FILES: ${{ steps.verify-changed-files.outputs.changed_files }}\n        run: |\n          echo \"Changed files: $CHANGED_FILES\"\n        # Outputs: \"Changed files: new.txt test_directory/new.txt\"\n```\n\n### Using the [`contains`](https://docs.github.com/en/actions/learn-github-actions/expressions#contains) function.\n\n```yaml\n...\n      - name: Verify Changed files\n        uses: tj-actions/verify-changed-files@a1c6acee9df209257a246f2cc6ae8cb6581c1edf # v20\n        id: verify-changed-files\n        with:\n          files: |\n             new.txt\n             test_directory\n\n      - name: Perform action when test_directory changes\n        if: contains(steps.verify-changed-files.outputs.changed_files, 'test_directory')\n        run: |\n          echo \"test_directory has changed.\"\n```\n\n### Get all unstaged (tracked/untracked) files\n\n```yaml\n...\n      - name: Verify Changed files\n        uses: tj-actions/verify-changed-files@a1c6acee9df209257a246f2cc6ae8cb6581c1edf # v20\n        id: verify-changed-files\n      \n      - name: List all changed tracked and untracked files\n        env:\n          CHANGED_FILES: ${{ steps.verify-changed-files.outputs.changed_files }}\n        run: |\n          echo \"Changed files: $CHANGED_FILES\"\n```\n\nIf you feel generous and want to show some extra appreciation:\n\nSupport this project with a :star:\n\n[![Buy me a coffee][buymeacoffee-shield]][buymeacoffee]\n\n[buymeacoffee]: https://www.buymeacoffee.com/jackton1\n\n[buymeacoffee-shield]: https://www.buymeacoffee.com/assets/img/custom_images/orange_img.png\n\n## Inputs\n\n\u003c!-- AUTO-DOC-INPUT:START - Do not remove or modify this section --\u003e\n\n```yaml\n- uses: tj-actions/verify-changed-files@a1c6acee9df209257a246f2cc6ae8cb6581c1edf # v20\n  id: verify-changed-files\n  with:\n    # Indicates whether to fail if \n    # files have changed. \n    # Type: boolean\n    # Default: \"false\"\n    fail-if-changed: ''\n\n    # Indicates whether to fail if \n    # no files have changed. \n    # Type: boolean\n    # Default: \"false\"\n    fail-if-unchanged: ''\n\n    # Message to display when `fail-if-changed` \n    # or `fail-if-unchanged` is set to \n    # `true`. \n    # Type: string\n    fail-message: ''\n\n    # File/Directory names to check for \n    # uncommited changes. \n    # Type: string\n    files: ''\n\n    # Separator used to split the \n    # `files` input \n    # Type: string\n    # Default: \"\\n\"\n    files-separator: ''\n\n    # Indicates whether to match files \n    # in `.gitignore` \n    # Type: boolean\n    # Default: \"false\"\n    match-gitignore-files: ''\n\n    # Relative path under GITHUB_WORKSPACE to \n    # the repository \n    # Type: string\n    # Default: \".\"\n    path: ''\n\n    # Use non-ASCII characters to match \n    # files and output the filenames \n    # completely verbatim by setting this \n    # to `false` \n    # Type: boolean\n    # Default: \"true\"\n    quotepath: ''\n\n    # Indicates whether to read `.gitignore`. \n    # The `.gitignore` file will be \n    # ignored if set to `false`. \n    # Overrides `match-gitignore-files` \n    # Type: boolean\n    # Default: \"false\"\n    read-gitignore: ''\n\n    # Apply sanitization to output filenames \n    # before being set as output. \n    # Type: boolean\n    # Default: \"true\"\n    safe_output: ''\n\n    # Output string separator.\n    # Type: string\n    # Default: \" \"\n    separator: ''\n\n```\n\n\u003c!-- AUTO-DOC-INPUT:END --\u003e\n\n## Outputs\n\n\u003c!-- AUTO-DOC-OUTPUT:START - Do not remove or modify this section --\u003e\n\n|                                  OUTPUT                                   |  TYPE  |                   DESCRIPTION                    |\n|---------------------------------------------------------------------------|--------|--------------------------------------------------|\n| \u003ca name=\"output_changed_files\"\u003e\u003c/a\u003e[changed\\_files](#output_changed_files) | string |              List of changed files               |\n| \u003ca name=\"output_files_changed\"\u003e\u003c/a\u003e[files\\_changed](#output_files_changed) | string | Boolean indicating that files have \u003cbr\u003echanged.  |\n\n\u003c!-- AUTO-DOC-OUTPUT:END --\u003e\n\n*   Free software: [MIT license](LICENSE)\n\n## Known Limitation\n\n\u003e \\[!WARNING]\n\u003e\n\u003e *   Using characters like `\\n`, `%`, `.` and `\\r` as output string separators would be [URL encoded](https://www.w3schools.com/tags/ref_urlencode.asp)\n\n## Report Bugs\n\nReport bugs at https://github.com/tj-actions/verify-changed-files/issues.\n\nIf you are reporting a bug, please include:\n\n*   Your operating system name and version.\n*   Any details about your workflow that might be helpful in troubleshooting.\n*   Detailed steps to reproduce the bug.\n\n## Contributors ✨\n\nThanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):\n\n\u003c!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section --\u003e\n\n\u003c!-- prettier-ignore-start --\u003e\n\n\u003c!-- markdownlint-disable --\u003e\n\n\u003ctable\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"https://github.com/max-kahnt-keylight\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/79849575?v=4?s=100\" width=\"100px;\" alt=\"Max Kahnt\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eMax Kahnt\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/tj-actions/verify-changed-files/commits?author=max-kahnt-keylight\" title=\"Documentation\"\u003e📖\u003c/a\u003e\u003c/td\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"https://wllm.no\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/1223410?v=4?s=100\" width=\"100px;\" alt=\"William Killerud\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eWilliam Killerud\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/tj-actions/verify-changed-files/commits?author=wkillerud\" title=\"Code\"\u003e💻\u003c/a\u003e\u003c/td\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"https://github.com/Minecraftschurli\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/23388022?v=4?s=100\" width=\"100px;\" alt=\"Minecraftschurli\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eMinecraftschurli\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/tj-actions/verify-changed-files/commits?author=Minecraftschurli\" title=\"Code\"\u003e💻\u003c/a\u003e \u003ca href=\"https://github.com/tj-actions/verify-changed-files/commits?author=Minecraftschurli\" title=\"Documentation\"\u003e📖\u003c/a\u003e \u003ca href=\"https://github.com/tj-actions/verify-changed-files/commits?author=Minecraftschurli\" title=\"Tests\"\u003e⚠️\u003c/a\u003e\u003c/td\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"https://stefanhoth.com\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/45467?v=4?s=100\" width=\"100px;\" alt=\"Stefan Hoth\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eStefan Hoth\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/tj-actions/verify-changed-files/commits?author=stefanhoth\" title=\"Code\"\u003e💻\u003c/a\u003e\u003c/td\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"https://home.boidol.dev/\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/652404?v=4?s=100\" width=\"100px;\" alt=\"Raphael Boidol\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eRaphael Boidol\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/tj-actions/verify-changed-files/commits?author=boidolr\" title=\"Documentation\"\u003e📖\u003c/a\u003e\u003c/td\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"https://github.com/Larspolo\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/11822478?v=4?s=100\" width=\"100px;\" alt=\"Lars\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eLars\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/tj-actions/verify-changed-files/commits?author=Larspolo\" title=\"Code\"\u003e💻\u003c/a\u003e \u003ca href=\"https://github.com/tj-actions/verify-changed-files/commits?author=Larspolo\" title=\"Tests\"\u003e⚠️\u003c/a\u003e \u003ca href=\"https://github.com/tj-actions/verify-changed-files/commits?author=Larspolo\" title=\"Documentation\"\u003e📖\u003c/a\u003e\u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n\u003c/table\u003e\n\n\u003c!-- markdownlint-restore --\u003e\n\n\u003c!-- prettier-ignore-end --\u003e\n\n\u003c!-- ALL-CONTRIBUTORS-LIST:END --\u003e\n\nThis project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftj-actions%2Fverify-changed-files","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftj-actions%2Fverify-changed-files","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftj-actions%2Fverify-changed-files/lists"}