Is there a way to get all commit history for a single branch?
See original GitHub issueI’m using this action like this (this works splendidly):
- name: Check Out Code
uses: actions/checkout@v2
with:
ref: ${{ env.BRANCH }}
fetch-depth: 0
I only need to get the entire commit history for just that one ${{ env.BRANCH }}
. But using fetch-depth: 0
gets all commit history for all branches and tags, which is unnecessary in my case. Is there a way to get the entire commit history for just the branch referenced in the ref
?
Issue Analytics
- State:
- Created 2 years ago
- Reactions:23
- Comments:9
Top Results From Across the Web
How to get commit history for just one branch? - Stack Overflow
This doesn't work if the branch has been merge into master. It only reports history back to the merge point, not all the...
Read more >2.3 Git Basics - Viewing the Commit History
Viewing the Commit History ; --shortstat. Display only the changed/insertions/deletions line from the --stat command. ; --name-only. Show the list of files ...
Read more >How to Show Commit History for One Branch Using Git Log ...
To show commit history using Git log with range, move to Git repo, check content list, open file, update and commit it, run...
Read more >Most common commands to view Git History for Git Commits
How to view Git Commit History of specific intervals? ... All the commits happened since that date comes as the output. It will...
Read more >How to View Commit History With Git Log - How-To Geek
Git tracks commits over time, allowing you to follow the progression and history of your code. While you can always use Github online...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
It would probably be better if there was just an action that set up credentials and let users run their own fetches.
Here’s the job yml for the workaround I just figured out for my use case of running tests and linting on pull requests on my team’s Nx monorepo, in case anyone else finds this later with a similar need: