Skip to content

Commit 81afcf8

Browse files
committed
Added builtin diff syntax into git commit messages
Updated README with installation instructions and better markdown highlighting
1 parent de92eec commit 81afcf8

File tree

3 files changed

+23
-3
lines changed

3 files changed

+23
-3
lines changed

README.md

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,19 @@
22

33
Syntax Highlighting for SublimeText / Text Mate
44

5+
## Installation
6+
7+
### With Package Control:
8+
9+
1. Run the `Package Control: Install Package` command, find and install the Git Commit Message Syntax plugin.
10+
1. Restart Sublime Text (if required)
11+
12+
### Manually:
13+
14+
1. Clone or download the git repo into your packages folder (in Sublime Text, find Browse Packages… menu item to open this folder)
15+
1. Restart Sublime Text editor (if required)
16+
17+
518
## How to make commits with Sublime Text
619
For the following options, you'll need to use the appropriate command from below:
720
**Note** for Windows, you must have `Build 3065` or lated to have command line support
@@ -14,19 +27,19 @@ This will allow for more editing options than just the git commit, like editing
1427
Add the following to your `.bashrc`:
1528
On Mac and Linux:
1629

17-
```
30+
```bash
1831
export EDITOR="subl -w"
1932
```
2033

2134
### Alternate Method: Ammend your `.gitconfig`
2235
You can run the following command to let git update your `.gitconfig`
2336

24-
```
37+
```bash
2538
git config --global core.editor 'subl -w'
2639
```
2740

2841
Or add the following line manually to your `.gitconfig`
29-
```
42+
```ini
3043
[core]
3144
editor = 'subl -w'
3245
```

commit-message.JSON-tmLanguage

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,5 +74,8 @@
7474
}
7575
}]
7676
}]
77+
},
78+
{
79+
"include": "source.diff"
7780
}]
7881
}

commit-message.tmLanguage

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,10 @@
171171
</dict>
172172
</array>
173173
</dict>
174+
<dict>
175+
<key>include</key>
176+
<string>source.diff</string>
177+
</dict>
174178
</array>
175179
<key>scopeName</key>
176180
<string>text.git-commit-message</string>

0 commit comments

Comments
 (0)