Note: By default, GitHub Desktop will push the tag that you create to your repository with the associated commit. You can discard one or more changed lines that are uncommitted. To confirm the changes, in the "Confirm Discard Changes" window, review the files affected and click Discard Changes. To select multiple files, click shift and click on the range of files you want to discard changes from.Ĭlick Discard Changes or Discard Selected Changes to discard changes to one or more files, or Discard All Changes to discard changes to all files since the last commit. In the list of changed files, select the files where you want to discard the changes since the last commit. You can recover discarded changes until the Trash is emptied. You can discard all uncommitted changes in one or more files, or you can discard specific lines you added.ĭiscarded changes are saved in a dated file in the Trash. This will remove the changes from the files on your computer. If you have uncommitted changes that you don't want to keep, you can discard the changes. ![]() The lines that are still highlighted in blue will be included in the commit. To exclude changed lines from your commit, click one or more changed lines so the blue disappears. This allows you to make separate, meaningful commits, such as keeping line break changes in a commit separate from code or prose changes. The rest of your changes will remain intact, so that you can make additional modifications and commits. If one file contains multiple changes, but you only want some of those changes to be included in a commit, you can create a partial commit. You can toggle the checkbox with the Spacebar or Enter keys after selecting a file. To add all changes in one or more files to a single commit, unselect the checkboxes next to the files you don't want included, leaving only the files you want in the commit. To add all changes in all files to a single commit, keep the checkbox at the top of the list selected. To access stashed changes, click Stashed Changes. The yellow icon indicates modified files. In the "Changes" tab in the left sidebar: To see the entire file, right-click in the diff view and click Expand Whole File.Īs you make changes to files in your text editor and save them locally, you will also see the changes in GitHub Desktop.To see the next few lines above or below the highlighted changes, click the arrow above or below the line numbers.If you need to see more of the file than GitHub Desktop shows by default, you can expand the diff. To hide whitespace changes so you can focus on more substantive changes, select Hide Whitespace Changes.The Unified view shows changes linearly, while the Split view shows old content on the left side and new content on the right side. ![]() ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |