atom-editorscriptcs

Not able to run Scriptcs scripts in Atom using atom-runner


I am trying to setup Atom editor on Mac for use with ScriptCs scripts. So I followed the guide to do that.

execvp(): No such file or directory

I have scriptcs as an alias in my .profile. Running scriptcs test.csx in the terminal used to launch Atom, works. It seems like Atom is not aware of the profile alias.

What should I do to make this work in Atom ?


Solution

  • Atom-runner is using a call to exec to invoke scriptcs directly, rather than going through a shell, so it won't be able to pick up anything that you have in your dotfiles. You'll either need to:

    1. Put scriptcs on your $PATH normally, rather than using an alias. Sometimes you can do this with symlinks or changing its installation directory, for example.
    2. Specify the absolute path to your scriptcs executable in your Atom config, instead:
    'runner':
      'extensions':
        'csx': '/full/path/to/where/you/installed/scriptcs'