You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/desktop/contributing-and-collaborating-using-github-desktop/committing-and-reviewing-changes-to-your-project.md
+24-21Lines changed: 24 additions & 21 deletions
Original file line number
Diff line number
Diff line change
@@ -35,48 +35,51 @@ As you make changes to files in your text editor and save them locally, you will
35
35
36
36
#### Creating a partial commit
37
37
38
-
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. The rest of your changes will remain intact, so that you can make additional modifications and commits. This allows you to make separate, meaningful commits, such as keeping line break changes in a commit separate from code or prose changes.
38
+
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. The rest of your changes will remain intact, so that you can make additional modifications and commits. This allows you to make separate, meaningful commits, such as keeping line break changes in a commit separate from code or prose changes.
39
39
40
-
When you review the diff of the file, the lines that will be included in the commit are highlighted in blue. To exclude the change, click the changed line so the blue disappears.
40
+
{% note %}
41
+
42
+
**Note:** Split diff displays are currently in beta and subject to change.
43
+
44
+
{% endnote %}
41
45
42
-

46
+
1. To choose how your changes are displayed, in the top-right corner of the changed file, use {% octicon "gear" aria-label="The Gear icon" %} to select **Unified** or **Split**.
47
+

48
+
2. To exclude changed lines from your commit, click one or more changed lines so the blue disappears. The lines that are still highlighted in blue will be included in the commit.
49
+

43
50
44
-
#### Discarding changes
51
+
### 3. Discarding changes
52
+
If you have uncommitted changes that you don't want to keep, you can discard the changes. This will remove the changes from the files on your computer. You can discard all uncommitted changes in one or more files, or you can discard specific lines you added.
45
53
46
-
You can discard all the uncommitted changes in one file, a range of files, or discard all changes in all files since the last commit.
54
+
Discarded changes are saved in a dated file in the Trash. You can recover discarded changes until the Trash is emptied.
47
55
48
-
{% mac %}
56
+
#### Discarding changes in one or more files
49
57
50
58
{% data reusables.desktop.select-discard-files %}
51
59
{% data reusables.desktop.click-discard-files %}
52
60

53
61
{% data reusables.desktop.confirm-discard-files %}
54
62

55
63
56
-
{% tip %}
64
+
#### Discarding changes in one or more lines
65
+
You can discard one or more changed lines that are uncommitted.
57
66
58
-
**Tip:** The changes you discarded are saved in a dated file in the Trash and you can recover them until the Trash is emptied.
59
-
60
-
{% endtip %}
67
+
{% note %}
61
68
62
-
{% endmac %}
69
+
**Note:** Discarding single lines is disabled in a group of changes that adds and removes lines.
63
70
64
-
{% windows %}
71
+
{% endnote %}
65
72
66
-
{% data reusables.desktop.select-discard-files %}{% data reusables.desktop.click-discard-files %}
67
-

68
-
{% data reusables.desktop.confirm-discard-files %}
69
-

73
+
To discard one added line, in the list of changed lines, right click on the line you want to discard and select **Discard added line**.
70
74
71
-
{% tip %}
75
+

72
76
73
-
**Tip:** The changes you discarded are saved in a file in the Recycle Bin and you can recover them until it is emptied.
77
+
To discard a group of changed lines, right click the vertical bar to the right of the line numbers for the lines you want to discard, then select **Discard added lines**.
74
78
75
-
{% endtip %}
79
+

76
80
77
-
{% endwindows %}
78
81
79
-
### 3. Write a commit message and push your changes
82
+
### 4. Write a commit message and push your changes
80
83
81
84
Once you're satisfied with the changes you've chosen to include in your commit, write your commit message and push your changes. If you've collaborated on a commit, you can also attribute a commit to more than one author.
Copy file name to clipboardExpand all lines: content/github/committing-changes-to-your-project/creating-a-commit-with-multiple-authors.md
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -31,7 +31,7 @@ For more information, see "[Setting your commit email address](/articles/setting
31
31
32
32
### Creating co-authored commits using {% data variables.product.prodname_desktop %}
33
33
34
-
You can use {% data variables.product.prodname_desktop %} to create a commit with a co-author. For more information, see "[Write a commit message and push your changes](/desktop/contributing-to-projects/committing-and-reviewing-changes-to-your-project#3-write-a-commit-message-and-push-your-changes)" and [{% data variables.product.prodname_desktop %}](https://desktop.github.com).
34
+
You can use {% data variables.product.prodname_desktop %} to create a commit with a co-author. For more information, see "[Write a commit message and push your changes](/desktop/contributing-to-projects/committing-and-reviewing-changes-to-your-project#4-write-a-commit-message-and-push-your-changes)" and [{% data variables.product.prodname_desktop %}](https://desktop.github.com).
35
35
36
36

37
37
@@ -75,4 +75,4 @@ The new commit and message will appear on {% data variables.product.product_loca
75
75
- "[Viewing a summary of repository activity](/articles/viewing-a-summary-of-repository-activity)"
76
76
- "[Viewing a project's contributors](/articles/viewing-a-projects-contributors)"
77
77
- "[Changing a commit message](/articles/changing-a-commit-message)"
78
-
- "[Committing and reviewing changes to your project](/desktop/contributing-to-projects/committing-and-reviewing-changes-to-your-project#3-write-a-commit-message-and-push-your-changes)" in the {% data variables.product.prodname_desktop %} documentation
78
+
- "[Committing and reviewing changes to your project](/desktop/contributing-to-projects/committing-and-reviewing-changes-to-your-project#4-write-a-commit-message-and-push-your-changes)" in the {% data variables.product.prodname_desktop %} documentation
Copy file name to clipboardExpand all lines: content/github/finding-security-vulnerabilities-and-errors-in-your-code/troubleshooting-the-codeql-workflow.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -66,7 +66,7 @@ For more information, see the workflow extract in "[Automatic build for a compil
66
66
* Building using a distributed build system external to GitHub Actions, using a daemon process.
67
67
* {% data variables.product.prodname_codeql %} isn't aware of the specific compiler you are using.
68
68
69
-
For C# projects using either `dotnet build` or `msbuild` which target .NET Core 2, you should specify `/p:UseSharedCompilation=false` in your workflow's `run` step, when you build your code. The `UseSharedCompilation` flag isn't necessary for .NET Core 3.0 and later.
69
+
For .NET Framework projects, and for C# projects using either `dotnet build` or `msbuild` that target .NET Core 2, you should specify `/p:UseSharedCompilation=false` in your workflow's `run` step, when you build your code. The `UseSharedCompilation` flag isn't necessary for .NET Core 3.0 and later.
70
70
71
71
For example, the following configuration for C# will pass the flag during the first build step.
0 commit comments