Cron / Crontab syntax highlighting for Sublime Text 2 and 3
- Total 2K
- Win 469
- OS X 949
- Linux 525
|Dec 14||Dec 13||Dec 12||Dec 11||Dec 10||Dec 9||Dec 8||Dec 7||Dec 6||Dec 5||Dec 4||Dec 3||Dec 2||Dec 1||Nov 30||Nov 29||Nov 28||Nov 27||Nov 26||Nov 25||Nov 24||Nov 23||Nov 22||Nov 21||Nov 20||Nov 19||Nov 18||Nov 17||Nov 16||Nov 15||Nov 14||Nov 13||Nov 12||Nov 11||Nov 10||Nov 9||Nov 8||Nov 7||Nov 6||Nov 5||Nov 4||Nov 3||Nov 2||Nov 1||Oct 31|
Crontab Syntax Highlighting
- Open Sublime Text 2/3
- Locate Preferences in the menu, click on “Browse Packages…”
- Create a folder named Crontab and copy everything from this repository in that folder
A recent addition was using a few different sytax types like
in the language definition syntax. This is a bit of a hack because Sublime Text does not
seem to have an easy way for a plugin to suggest colors for the language scopes. In
addition, it is hard to know what scopes will be available in a theme, so with most
meta.minute.crontab will show up the same. This led me to believe
the plugin was 'broken' when it was first installed because everything was one color.
The syntax will look acceptable with most themes with these revised scopes:
keyword.at.crontab keyword.minute.crontab constant.hour.crontab class.dayofmonth.crontab keyword.month.crontab constant.dayofweek.crontab string.command.crontab
This will at least give it some syntax coloring with most themes - but still allow themes to override the colors.
If you would like to make the colors look more like the
vim darkbg style,
add the definitions from the included
optional-add-to-theme.xml file to your theme, or
perhaps use the Sublime Theme Editor to customize.