Skip to content
Syntax highlighting and function indexing for Swift code in BBEdit
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
LICENSE
README.md
identChars.swift
swift.plist Update swift.plist Dec 17, 2015

README.md

A BBEdit Codeless Language Module for Swift

Status

Keyword, comment, and string highlighting work. Top-level classes, structs, enums, functions, and extensions are indexed and can be folded. Because of limitations in the matching power of codeless language modules, nested declarations are not indexed and are not fold-able.

Installation

  1. Copy the file swift.plist to ~/Library/Application Support/BBEdit/Language Modules. You may have to create the Langauge Modules folder if it doesn’t exist.
  2. Quit and relaunch BBEdit.

Now files with the extension “swift” should be syntax highlighted. The function popup menu in the navigation bar should also list all the declarations in the current file.

Known Issues

  • Extensions are only indexed by base type. This means that multiple extensions of the same base type have the same identifier in the function popup menu.
  • Identifier matching does not include the full unicode ranges allowed by the Swift language reference. Only upper and lower case A-Z, 0-9, and ‘_’ are matched. I’m sorry for the lack of diacritic and emoji support, but I haven’t yet sorted out how to convince BBEdit to handle them in Identifier and Keyword Character Class.
  • Because of limitations in the matching power of codeless language modules, nested declarations are not indexed and are not fold-able.
You can’t perform that action at this time.