   provideLinter: ->
     helpers = require 'atom-linter'
     fs = require 'fs'
-
+    regex = 'scala:(?<line>\\d+): (?<type>(error|warning)): (?<message>(.+))'
     provider =
       grammarScopes: ['source.scala']
       scope: 'file'
-      lintOnFly: true
+      lintOnFly: false
       lint: (textEditor) =>
         filePath = textEditor.getPath()
-        if @scalacExecutablePath
-          command = @scalacExecutablePath + '/' + @cmd
-        else
-          command = @cmd
         args = @scalacOptions.split(' ')
+        command = atom.config.get 'linter-scalac.scalacExecutablePath'
         if helpers.findFile(filePath, '.classpath')
           dotClasspath = helpers.findFile(filePath, '.classpath')
           classpath = fs.readFileSync(dotClasspath).toString().trim()

  config:
    scalacExecutablePath:
      type: 'string'
      default: ''
    scalacOptions:
      type: 'string'
      default: '-Xlint'

    @subscriptions.add atom.config.observe 'linter-scalac.scalacOptions',
      (scalacOptions) =>
        @scalacOptions = scalacOptions

  deactivate: ->
    @subscriptions.dispose()
