Skip to content

Instantly share code, notes, and snippets.

@robmccormack
Last active December 19, 2015 09:39
Show Gist options
  • Save robmccormack/5935104 to your computer and use it in GitHub Desktop.
Save robmccormack/5935104 to your computer and use it in GitHub Desktop.
Sublime Text - settings file with comments (*.settings files are .json files, and can't have comments) Solution: make a tag that does nothing, for comments.
{
"my_setting_comments":
[
"json files CAN NOT have comments,they are stripped out",
"TIP: use underscore like this to disable (with quotes) theme_: Phoenix Dark.sublime-theme",
"Comment1",
"Comment2"
],
"caret_style": "wide",
"color_scheme": "Packages/Theme - Phoenix/Color Scheme/Tomorrow-Night.tmTheme",
"fade_fold_buttons": false,
"font_size": 15.0,
"highlight_active_tab": true,
"highlight_line": true,
"highlight_modified_tabs": true,
"ignored_packages":
[
"Vintage"
],
"line_padding_bottom": 2,
"line_padding_top": 3,
"trim_trailing_white_space_on_save": true
}
<snippet>
<content><![CDATA[
"my_setting_comments":
[
"json files CAN NOT have comments,they are stripped out",
"TIP: use underscore like this to disable (with quotes) theme_: Phoenix Dark.sublime-theme",
"Comment1",
"Comment2"
],
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>settings</tabTrigger>
<description>settings comments</description>
<!-- Optional: Set a scope to limit where the snippet will trigger -->
<!-- <scope>source.json</scope> -->
</snippet>
@robmccormack
Copy link
Author

From android.

@robmccormack
Copy link
Author

From android

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment