command strings executed in shell as array of characters
kevzettler opened this issue · 5 comments
I have the following iTermocil.yml
file in my projects directory
windows:
- name: client-dev
root: ./
command: yarn client-dev
- name: server-dev
root: ./
command: yarn server-dev
When I execute itermocil
iTerm opens 2 new tabs and executes the commands as semicolon delimited arrays of characters like:
Kevs-MBP-2:cra kev$ y; a; r; n; ; c; l; i; e; n; t; -; d; e; v
-bash: syntax error near unexpected token `;'
and
Kevs-MBP-2:cra kev$ y; a; r; n; ; s; e; r; v; e; r; -; d; e; v
-bash: syntax error near unexpected token `;'
This fails to actually execute the commands
This is
iTerm2: Build 3.1.6beta5
and
itermocil --version
0.2.1
@kevzettler Slow reply, sorry.
That is really weird. Did it work after an iTerm update?
I had to update the yaml to prefix the commands with a hyphen like:
windows:
- name: client
commands:
- yarn dev-client
- name: server
layout: even-vertical
panes:
- yarn dev-server
- nodemon build/server.js
@kevzettler I don't think this is resolved, it's just that you are using the commands
instruction which takes a list instead of the command
instruction that is supposed to take a single argument.
command: yarn server-dev
Should be the same as:
commands:
- yarn server-dev
But as mentioned in the issue description, the command
instruction will split the instruction into y; a; r; n; ; c; l; i; e; n; t; -; d; e; v
.
So I think either the command
instruction should be dropped or the bug should be fixed...