             (executablePath) =>
                 @executablePath = executablePath
 
+        @subscriptions.add atom.config.observe "#{pkg.name}.executableCwd",
+            (executableCwd) =>
+                @executableCwd = executableCwd
+
         @subscriptions.add atom.config.observe "#{pkg.name}.incPathsFromProjectRoot",
             (includePaths) =>
                 @includePaths = includePaths


        sourceCode = textEditor.getText()

        return helpers.exec(
            settings.executablePath,
            parameters,
            {
                stdin: sourceCode,
                stream: 'both',
                cwd: fileDir}
            ).then (result) ->
                messages = []
                regex = namedRegExp.named(REGEX)

            type: "string"
            title: "Perl executable path"
            default: "perl"
        executableCwd:
            type: "string"
            title: "Current working directory for execution"
            default: ""
        incPathsFromProjectRoot:
            type: "array"
            title: "Include paths from project root"
