On SublimeText we can have a vertical line at 100 character position, adding the following to settings
"rulers":[100],
I would like to have the same on SublimeMerge. Is that possible?
On SublimeText we can have a vertical line at 100 character position, adding the following to settings
"rulers":[100],
I would like to have the same on SublimeMerge. Is that possible?
Copyright © 2021 Jogjafile Inc.
You can indeed do this in Merge, but the setting needs to go into a different place.
In Sublime Text, the setting in
Preferences.sublime-settingsare applied to editing views by default (since Text is a text editor first and foremost) and then those settings can be further enhanced in other ways, such as syntax specific settings, project settings, and so on.Since Merge isn't a Text editor by default, adding the
rulerssetting toPreferences.sublime-settingsdoesn't have any effect because there aren't any file views to apply the setting to.What you can do instead though is use
Preferences > Browse Packagesin Merge to open up yourUserpackage, and then create a file in that location namedCommit Message.sublime-settingswith contents such as the following:Here two settings are applied; the syntax is changed from the default to a syntax from the
Git Formatspackage (which ships with Sublime Text and Sublime Merge) and rulers are applied.The syntax enhances the syntax highlighting for commit messages by highlighting things like
#13when referencing GitHub issues or@usernamecallouts, etc which can be handy if you use those sorts of things in your commit messages.This also sets up the
rulerssetting as well. In this example there are two of them because commit message standards are sometimes defined by wanting the first line of a commit message to be no longer than 50 characters and the remaining lines no longer than 70 or 72, etc.The order of the rulers matters in as much as the first ruler added (here 72) is where the
Edit > Wrap Paragraphcommand will wrap, so if you want more than one visual ruler you'd set the first one to be where you want the wrap to happen./This settings file only applies to the edit area for commits that you're making or editing, but it doesn't apply to the display of commit messages for existing commits (such as when browsing the graph). If you would like to apply settings to those (such as adding rulers there as well or changing the syntax) you would do that by creating a
Commit Message (Read Only).sublime-settingsfile instead.