F5 iRules
Sublime Text package for F5 iRules syntax highlighting and auto-completion
Details
Installs
- Total 1K
- Win 712
- Mac 399
- Linux 129
| Sep 14 | Sep 13 | Sep 12 | Sep 11 | Sep 10 | Sep 9 | Sep 8 | Sep 7 | Sep 6 | Sep 5 | Sep 4 | Sep 3 | Sep 2 | Sep 1 | Aug 31 | Aug 30 | Aug 29 | Aug 28 | Aug 27 | Aug 26 | Aug 25 | Aug 24 | Aug 23 | Aug 22 | Aug 21 | Aug 20 | Aug 19 | Aug 18 | Aug 17 | Aug 16 | Aug 15 | Aug 14 | Aug 13 | Aug 12 | Aug 11 | Aug 10 | Aug 9 | Aug 8 | Aug 7 | Aug 6 | Aug 5 | Aug 4 | Aug 3 | Aug 2 | Aug 1 | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Windows | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| Mac | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 |
| Linux | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
Readme
- Source
- raw.githubusercontent.com
sublime-f5-irules
Description
Sublime Text package for F5 iRules syntax highlighting and auto-completion.
Installation
Package Control
This is the recommended way to install the package. Package Control will install the latest release on your system and keep it up to date:
- Make sure Package Control is installed
- Open the Command Palette from the main menu of Sublime Text (Tools → Command Palette or ⌘+⇧+P)
- Start typing:
Package Control: Install Packageand select the command to show a list of all available packages - Type:
F5 iRulesand select it to install the package
Manual (Windows, Linux, macOS)
- Download the master branch archive
- Open the Packages directory from the main menu of Sublime Text (Preferences → Browse Packages…)
- Extract the archive into its own folder under the Packages directory
Git
Linux:
cd ~/.config/sublime-text-3/Packages
git clone https://github.com/ArtiomL/sublime-f5-irules.git
macOS:
cd ~/Library/Application\ Support/Sublime\ Text\ 3/Packages/
git clone https://github.com/ArtiomL/sublime-f5-irules.git
Color Scheme
Please use the MonokaiRule theme included in this package for optimal highlighting experience.
Otherwise, add the following scopes to your current color scheme:
| Scope | Suggested Color |
|---|---|
| keyword.name.event.irule | #66D9EF |
| keyword.control.irule | #7FE22A |
| keyword.operator.irule | #FF971F |
| keyword.log.irule | #F19090 |
| keyword.disabled.irule | #FF0000 |
| variable.other.irule | #AE81FF |
| command.httpheader.irule | #88FFFF |
Example:
<dict>
<key>scope</key>
<string>keyword.name.event.irule</string>
<key>settings</key>
<dict>
<key>foreground</key>
<string>#66D9EF</string>
</dict>
</dict>
Filetypes and Syntax Association
The package syntax is used for .irule files by default.
Using the .txt extension is also supported: the first line of the file should begin with the following sequence:
#!iRule
Or you can set the syntax manually:
- Open the Command Palette from the main menu of Sublime Text (Tools → Command Palette or ⌘+⇧+P)
- Start typing:
Set Syntax: iRuleorssirand select the command to activate it
Snippets
Code snippets are small blocks of reusable code that can be inserted into a file to avoid repetitive typing.
Start typing one of the following:
ACCESS
class
HTTP
for
foreach
if
ILX
log
set
switch
when
and select the command… from the context menu (Tab).
Pseudo-Validation
Highlighting for a specific scope will be disabled (to indicate an error) based on the following set of rules:
Spaces
- Only a single space should be used between the highlighted commands, arguments and operators
Events
- The when statement can't start with a whitespace
- Only a single space should be used between the when keyword and the EVENT_NAME
- The EVENT_NAME should only contain capital letters, underscores and numerals 2 and 7 (for ACCESS2_POLICY_EXPRESSION_EVAL and IN_DOSL7_ATTACK)
More
- In development