Find what files changed in a pushed commit? #25170
-
I want to get the file names or relative path of the changed files triggered by push. I am already filtering the action with the on.push.paths functionality in the workflow. I need to find what specific files changed as I am going to run a process on them and would like to only run it on the changed files.
|
Beta Was this translation helpful? Give feedback.
Replies: 6 comments
-
Please use below command to get the changed files in the push commit, please refer to this link for more details.
|
Beta Was this translation helpful? Give feedback.
-
Thanks that worked great. Now I just need to figure out how to pipe that into the next step. |
Beta Was this translation helpful? Give feedback.
-
"Thanks that worked great. Now I just need to figure out how to pipe that into the next step. " I’m working on the same thing. Please post if you find a solution and I’ll do the same. |
Beta Was this translation helpful? Give feedback.
-
What if I pushed more than one commits at once? What would ${{ github.sha }} contain? |
Beta Was this translation helpful? Give feedback.
-
Hi @andyli , For multi commits, you can find my anwser in this ticket. Thanks. |
Beta Was this translation helpful? Give feedback.
-
Monitor github file changes on commits, PRs, etc (on any repo) and get a notification using webhooks, look for patterns, review diffs, take actions, etc. Source code is available here: https://github.com/DevScoreInc/samples/tree/master/github-file-monitor Demo is here: https://youtu.be/6HgxIkT8EQ4 Free to deploy and use. |
Beta Was this translation helpful? Give feedback.
Please use below command to get the changed files in the push commit, please refer to this link for more details.