ctrl+shift+p filters: :st2 :st3 :win :osx :linux
Browse

Sublime​Anarchy

by drewcrawford, dunkelstern ST3 MacLinux

SourceKit can crash more than just Xcode

Details

Installs

  • Total 128
  • Win 0
  • Mac 83
  • Linux 45
Jul 26 Jul 25 Jul 24 Jul 23 Jul 22 Jul 21 Jul 20 Jul 19 Jul 18 Jul 17 Jul 16 Jul 15 Jul 14 Jul 13 Jul 12 Jul 11 Jul 10 Jul 9 Jul 8 Jul 7 Jul 6 Jul 5 Jul 4 Jul 3 Jul 2 Jul 1 Jun 30 Jun 29 Jun 28 Jun 27 Jun 26 Jun 25 Jun 24 Jun 23 Jun 22 Jun 21 Jun 20 Jun 19 Jun 18 Jun 17 Jun 16 Jun 15 Jun 14 Jun 13 Jun 12
Windows 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
Mac 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
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 1 0 0 0 0 0

Readme

Source
raw.​githubusercontent.​com

Sublime Text 3 plugin for developing with the Open Source Version of Swift

This plugin is specifically designed to work with the Anarchy Tools build system and package manager.

Features

  • Swift 3 Syntax highlighting
  • build.atpkg Syntax hilighting
  • Building with atbuild
  • Highlighting build errors in the source files
  • Build log (terminal output) in an output panel in Sublime with output coloring and clickable file names

Some features currently only work on OSX:

  • SourceKit autocompletion
  • SourceKit documentation fetching (kind of buggy, blame SourceKit)

Roadmap

  • SourceKit as you type error display
  • Package manager support
  • Showing just an interface of a Swift file without implementation
  • Jump to definition
  • Find callers

Setup

Use the default Sublime method of overriding configuration from the menu. Available configuration options:

  • sourcekit_path path to sourcekitd (default: /Library/Developer/Toolchains/swift-latest.xctoolchain/usr/lib/sourcekitd.framework/sourcekitd)
  • sourcekit_sdk path to the sdk SourceKit shall use (default: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk)
  • atbuild_path path to the atbuild binary from Anarchy Tools (default: /usr/local/bin/atbuild)
  • atpm_path path to the atpm binary from Anarchy Tools (default: /usr/local/bin/atpm)

How to use

The syntax highlighter should work out of the box (make sure you don't have another swift syntax hilighter installed), for the build process to work you'll need to open a Sublime project file.

Example content of Project.sublime-project:

{
    "folders": [
        {
            "path": ".",
            "folder_exclude_patterns": [ ".atllbuild", "bin" ],
        }
    ]
}

Put that into your project root and use the menu entry Project->Open Project... to open the project (or double-click in your filesystem browser or even open with subl <ProjectFile> from the command line.)

If the project is open just use the Command Palette to execute some Anarchy Tools commands (all prefixed with AnarchyTools:). To speed up rebuilding the last target you built use the shortcut CMD-SHIFT-A (OSX) or CTRL-SHIFT-A (Linux) to re-execute the last chosen task.