Partial commits in GitHub for Mac
Sometimes when you’re in the zone, you get a ton of work done before you have a chance to pause and commit. You want to break the commit down to…
Sometimes when you’re in the zone, you get a ton of work done before you have a chance to pause and commit. You want to break the commit down to describe the logical changes you’ve made, and it doesn’t always break down cleanly file by file. You want to select some parts of your changes to commit at a time. That’s easy in GitHub for Mac.
Select one or more lines to commit by clicking on the line numbers in the gutter. In the latest release, you can select a block of changes at a time. Hover over the right hand side of the line numbers to get a preview of what will be selected, and click to select.
You can select multiple lines or blocks of changes by clicking and dragging. The left of the line numbers will select line by line, and the right will select block by block.
Now you can commit your selected changes, leaving the rest for a later commit.
Written by
Related posts
Code referencing now generally available in GitHub Copilot and with Microsoft Azure AI
Announcing the general availability of code referencing in GitHub Copilot and Microsoft Azure AI, allowing developers to permit code suggestions containing public code matches while receiving detailed information about the match.
The nuances and challenges of moderating a code collaboration platform
Sharing the latest data update to our Transparency Center alongside a new research article on what makes moderating a code collaboration platform unique.
GitHub Copilot now available in github.com for Copilot Individual and Copilot Business plans
With this public preview, we’re unlocking the context of your code and collaborators—and taking the next step in infusing AI into every developer’s workflow.