Skip to content

Instantly share code, notes, and snippets.

@tomaskrehlik
Last active August 29, 2015 14:09
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tomaskrehlik/0e8b65d48e2b4f9af85d to your computer and use it in GitHub Desktop.
Save tomaskrehlik/0e8b65d48e2b4f9af85d to your computer and use it in GitHub Desktop.
Settings for Julia linter
#
# linter.py
# Linter for SublimeLinter3, a code checking framework for Sublime Text 3
#
# Written by Tomas Krehlik
# Copyright (c) 2014 Tomas Krehlik
#
# License: MIT
#
"""This module exports the Julialint plugin class."""
from SublimeLinter.lint import Linter, util
class Julialint(Linter):
"""Provides an interface to julialint."""
syntax = 'julia'
cmd = '/............./test.sh'
executable = None
regex = r'(?P<file>^.*\.jl):(?P<line>\d{1,4}) \[(?P<func>.*)\] ((?P<error>ERROR)|(?P<warning>WARN)) (?P<message>.*)'
multiline = False
line_col_base = (1, 1)
tempfile_suffix = "jl"
error_stream = util.STREAM_BOTH
selectors = {}
word_re = None
defaults = {}
inline_settings = None
inline_overrides = None
comment_re = None
@tomaskrehlik
Copy link
Author

And the bash script is

#!/bin/bash
/Applications/Julia-0.3.5.app/Contents/Resources/julia/bin/julia -e "using Lint; lintfile(\"$1\")"

where the first is just a path to any executables. You also have to have Lint package installed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment