Skip to content
This repository

ColdFusion Sublime Text Package

branch: master

Adding support for the dollar sign ($) in a function name. This is a …

…convention being used for example in the CFWheels Framework.
latest commit ee54c80589
charlycontreras charlycontreras authored June 25, 2013
Octocat-spinner-32 importer Update importer, and implement CF10 with backwards compatibility to CF7. June 24, 2012
Octocat-spinner-32 snippets prevents snippets from triggering in meta scope June 27, 2012
Octocat-spinner-32 taglib Update importer, and implement CF10 with backwards compatibility to CF7. June 24, 2012
Octocat-spinner-32 .gitignore gitignore September 12, 2012
Octocat-spinner-32 CFScript.sublime-completions removes new line in var cfscript completion October 21, 2012
Octocat-spinner-32 CFScript.tmPreferences enabled line comments in cfscript February 03, 2012
Octocat-spinner-32 CFScriptEmbedded.tmPreferences refactor May 29, 2012
Octocat-spinner-32 CFScriptFunctionArgs.sublime-completions fixes cfscript meta.function.parameters completions December 08, 2012
Octocat-spinner-32 Cfscript.tmLanguage Adding support for the dollar sign ($) in a function name. This is a … June 25, 2013
Octocat-spinner-32 ColdFusion.sublime-settings changes default auto_indent_on_close to true October 09, 2012
Octocat-spinner-32 ColdFusion.tmPreferences adds cftrace to decreaseindent #85 September 21, 2012
Octocat-spinner-32 ColdFusionCFC.tmLanguage adds missing punctuation definition for cfc cfml comment blocks September 17, 2012
Octocat-spinner-32 Coldfusion.tmLanguage closes #108 punctuation.definition.tag.begin/end is used to match tag… February 15, 2013
Octocat-spinner-32 Default (OSX).sublime-keymap allows dot completions in between hash tags closes #102 November 01, 2012
Octocat-spinner-32 Default.sublime-commands Changed CFLIB ColdFusion command caption adds CFlib for faster fuzzy … June 04, 2012
Octocat-spinner-32 Default.sublime-keymap allows dot completions in between hash tags closes #102 November 01, 2012
Octocat-spinner-32 HTML+CFML.tmLanguage bad regex here, errant unnecessary asterisk February 05, 2013
Octocat-spinner-32 JavaDoc Add Line.sublime-macro added Java Doc style keyboard shortcuts and macros for inserting aste… January 24, 2012
Octocat-spinner-32 JavaDoc Delete Line.sublime-macro removed add line before macro for JavaDock and shortcuts January 24, 2012
Octocat-spinner-32 Main.sublime-menu added key mappings to menu June 28, 2012
Octocat-spinner-32 Symbol List Queries.tmPreferences added symbol support for cfscript queries February 09, 2012
Octocat-spinner-32 Symbol List.tmPreferences removed function name meta.toc-list.function (not needed) February 23, 2012
Octocat-spinner-32 Terminate Statement.sublime-macro use ctrl+enter or arrow keys to move to the next line May 24, 2012
Octocat-spinner-32 brackets.tmPreferences #66 changes brackets.tmPreferences to use default javascript style cu… September 08, 2012
Octocat-spinner-32 cflib.py attempt fix #65 - moves getCategories() from constructor to run function September 09, 2012
Octocat-spinner-32 cfml.py no docs for on_query_completions but this works June 24, 2012
Octocat-spinner-32 coldfusiontagcompletions.py Changes tag attribute completions scope to just meta.tag so that it w… December 04, 2012
Octocat-spinner-32 functioncompletions.py pass IOError cfc_file file not found August 01, 2012
Octocat-spinner-32 ondotcompletions.py Regression bug #102 allows inserting periods on multiple selection November 14, 2012
Octocat-spinner-32 package-metadata.json updates package json June 24, 2012
Octocat-spinner-32 readme.md updates Readme to include Sublime Text 3 Note/Info January 30, 2013
Octocat-spinner-32 tagoperators.py fixes auto-complete for component tag operator attributes December 03, 2012
readme.md

ColdFusion Package for Sublime Text

Sublime Text 3

The development branch contains a rewrite of the ColdFusion plugin. The only installation method is via Git.

cd Packages/
git clone https://github.com/SublimeText/ColdFusion.git
cd ColdFusion
git checkout development
  • CFLIB Command is not currently working.
  • Tag Operator Completions is not yet implemented
  • CFScript component method completions is not yet implemented
  • Only CF10 Dictionary is imported.

What's New

  • Added Tag Operator completions for cfscript (10/21/12)
  • Added CFScript component method completions (6/28/12)
  • Added "auto_close_cfml", "auto_indent_on_close" settings (6/25/12)
  • Added Tag Attribute completions (6/24/12)
  • Added Command ColdFusion: Insert CFlib UDF (6/2/12)

Features

  • ColdFusion cfml, and script-based CFCs syntax highlighting. (see tmLanguage files)
  • Auto inserts closing hash # (see Default (platform).sublime-keymap)
  • Provides completions that match just after typing an opening angle bracket (see cfml_completions.py)
  • Auto Complete ColdFusion Tags and Attributes (opt. cf7, cf8, cf9 & cf10)
  • ColdFusion specific key bindings (see Default (platform).sublime-keymap)

Installation

The recommended method of installation is via Package Control.

Package Control

Using Git

Go to your Sublime Text 2 Packages directory and clone the repository using the command below:

git clone https://github.com/SublimeText/ColdFusion

Download Manually

  • Download the files using the GitHub .zip download option
  • Unzip the files and rename the folder to ColdFusion
  • Copy the folder to your Sublime Text 2 Packages directory

Key bindings

Some packages will override key bindings. If you have problems with a specific key shortcut, you can add it to your User - Key Bindings file Preferences > Key Bindings - User

You can also use sublime.log_commands(True) in the console (ctrl+~) to output key presses and their corresponding command to the console pane.

+# #SELECTION# Ctrl++O <cfoutput>SELECTION</cfoutput>
Ctrl++# <cfoutput>#SELECTION#</cfoutput> Ctrl+Alt+A <cfabort />
Ctrl+Alt+D <cfdump var="#SELECTION#"> Alt++R <cfscript>SELECTION</cfscript>
Ctrl++/ block comment (cfml/cfscript) Ctrl+Alt++/ javadoc comment
Alt+ terminates statement (cfscript) Ctrl++= <cfset SELECTION />

Many more key bindings are available via Sublime Preferences > Key Bindings - Default

Completions and Snippets

Although, this package includes CFScript completions (.sublime-completions) and ColdFusion tag completions (API-injected), it's recommended that you create your own custom snippets using code that fits your particular coding style. To create a new snippet select Tools > New Snippet... from the Sublime Text menu. Use <scope>text.html.cfm - string</scope> for ColdFusion markup snippets and <scope>source.cfscript - string</scope> for CFScript snippets.

Completions in order of priority are:

  • Snippets
  • API-injected completions
  • .sublime-completions files
  • words in the current buffer

The following list contains snippets repositories made available by ColdFusion community members:

To install snippets just put the .sublime-snippet files in your Packages/User folder or sub-folder (to get to your Packages/User folder select Preferences > Browse Packages... from the Sublime Text 2 menu).

Custom Themes

The following themes optimized for ColdFusion are made available by ColdFusion community members and can be installed with Package Control (http://wbond.net/sublime_packages/community)

If you'd like to customize your favorite theme for ColdFusion support, you can use the entity.name.tag.cf scope in your tmTheme file. For example the following definition will use the color #C87551 for all ColdFusion tags:

<dict>
    <key>name</key>
    <string>Meta</string>
    <key>scope</key>
    <string>meta.tag.block.cf, meta.tag.inline.cf</string>
    <key>settings</key>
    <dict>
        <key>fontStyle</key>
        <string></string>
        <key>foreground</key>
        <string>#C87551</string>
    </dict>
</dict>
<!-- this will color ColdFusion tag name -->
<dict>
    <key>name</key>
    <string>Entity</string>
    <key>scope</key>
    <string>entity.name.tag.cf</string>
    <key>settings</key>
    <dict>
        <key>fontStyle</key>
        <string></string>
        <key>foreground</key>
        <string>#C87551</string>
    </dict>
</dict>

You can use Ctrl+Alt++P to get the scope name at the cursor position for more theme customizing .

Development Branch

To help test the development branch you can install it by dowloading the zip and copying the contents to the Packages/ColdFusion folder.

Alternatively, you can use git to install the ColdFusion package as mentioned above and switch to the development tracking branch using:

git checkout development

Additional Packages

Some additional packages you might want to check out - they are all available through Package Control http://wbond.net/sublime_packages/community

These packages require manual installation

License

Copyright (c) 2012

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Something went wrong with that request. Please try again.