actions-go/modified-file

Sets outputs wheter and which matching files has been modified since between 2 commits It is the equivalent of `git log base..head`. It uses the github API to compare both commits: https://developer.github.com/v3/repos/commits/#compare-two-commits

View on GitHub

Trust Signals

Scorecard Score
not yet scored
Maintenance Recency
Stalelast commit Feb 8, 2022
License
MIT
Runtime
Deprecated runtime

Pinned Snippet

workflow.ymlSHA-pinned
uses: actions-go/modified@b272e2455b3cce9fe2f7b49cca8bd86aa7769d77 # no releases — HEAD as of 2026-07-22

tags can be moved; commit SHAs can't. why a SHA?

namedescriptionrequireddefault
headThe commit to be compared to base. This parameter is required when running on an event different from push or pullrequest. When handling a pullrequest event, it defaults to the pullrequest head sha. When handling a push event, it defauts to the `After` field of the push event: https://developer.github.com/v3/activity/events/types/#pushevent
baseThe commit head is compared to. This parameter is required when running on an event different from push or pullrequest. When handling a pullrequest event, it defaults to the pullrequest base sha. When handling a push event, it defauts to the `Before` field of the push event: https://developer.github.com/v3/activity/events/types/#pushevent
patternyes
use-globWhether to use the simplee glob syntax, extended with the `**` pattern matching paths with path separator true
tokenAuth token used to fetch the repository. The token is stored in the local git config, which enables your scripts to run authenticated git commands. The post-job step removes the token from the git config. [Learn more about creating and using encrypted secrets](https://help.github.com/en/actions/automating-your-workflow-with-github-actions/creating-and-using-encrypted-secrets) ${{ github.token }}
namedescription
modifiedtrue when any modified file between base and head matches pattern
modified-filesa json encoded list of all files modified between base and head