You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Seem there an issue with single quotes inside commands eg.
git commit -m 'some thing here'
results in the 'some thing here' part becoming 3 seperate paramters and ended up having to chane to escaped double quotes.
Also commands are too isolated indicating a different approach is needed.
eg, this fails because the cd command is isolated so the next command does not happen inside the expected directory.
CLI::batchPassThru(
[
"git clone https://github.com/b-hayes/php-apache-template $name",
"cd $name",
"git branch"//list the branches before asking what to use.
]
);
It would be better if all the commands are imploded with a set x so that the entire set stops on the first error.
I also thought about being able to specify a cleanup operation tho the user can just catch the exception and do it that way anyway. Perhaps think about it and change the exception type.
The text was updated successfully, but these errors were encountered:
b-hayes
changed the title
Batch Passthru has an issue with each command being isolated.
BUG: Batch Passthru has an issues
Oct 27, 2023
Seem there an issue with single quotes inside commands eg.
results in the 'some thing here' part becoming 3 seperate paramters and ended up having to chane to escaped double quotes.
Also commands are too isolated indicating a different approach is needed.
eg, this fails because the cd command is isolated so the next command does not happen inside the expected directory.
It would be better if all the commands are imploded with a
set x
so that the entire set stops on the first error.I also thought about being able to specify a cleanup operation tho the user can just catch the exception and do it that way anyway. Perhaps think about it and change the exception type.
The text was updated successfully, but these errors were encountered: