I am creating a faster workflow for working with a BigCommerce (Spotify competitor) theme and found this basic release tool which had a lot of stars and seemed light and simple. I wanted to in one command run tests, create a release (with all the trimmings in the /release tabs in my GitHub repo for the theme) and use BigCommerce's tools to update the ecom store with the latest theme.

The release-it tool I linked above has a spot in it's config where it will fire a specified command after it's done with the release. BigCommerce has a tool called stencil that has a simple one-line command stencil push to upload and publish on the site. All this works fine as separate steps but I'm trying to just make it one button.

Question: When release-it finishes and executes stencil-push it looks like the following picture below - the command fires next to a spinner (not sure if this is builtin to the terminal or not) and sits there.

enter image description here

When this command is ran normally it is interactive, outputting stuff, and ultimately needs a y/N response to confirm the upload, which I cannot do as it spins with no output or input taken.

I am not sure what is happening here, if release-it is executing the command in a way I'm unfamiliar with. Two things I've tried are changing the command to . stencil push or source stencil push, and putting the whole command into an executable shell script, and telling release-it to execute this. Same result.

Thanks for any help figuring out my issue.

  • 1
    Does the Stencil tool have a non-interactive mode you can use? CI tools cannot generally accept input in an interactive manner, so it's probably getting stuck at the Y/N prompt. You could run release-it -VV to get more information on what's happening. – Haxiel Jan 5 at 4:44
  • 1
    @Haxiel thank you for your responses and your time. I agree with you, this appears part of the release-it tool. I have completed a workaround that simply makes a new script which calls release-it and once that completes successfully, stencil push is then called. I am still curious to learn about what might be happening, do you know if it would be possible for release-it to takes a command and force it into this state? where it is suppressing stdout from the command line and just wrapping it in a spinner? How would it potentially go about doing that? – stupidkid Jan 6 at 14:45
  • 1
    I think it's a simple matter of redirection. stencil push </dev/null should exhibit the same behaviour. Here, we're overriding the standard input (from the keyboard) with the null file, so the program cannot accept interactive input. Output and error can be redirected the same way. CI tools generally collect the output and error streams to a file, so that they can be looked at later on. – Haxiel Jan 7 at 13:14
  • 1
    For the spinner, you can take a look at the code directly. I'm not very familiar with JS, but the code seems to initializing a spinner with a corresponding task, and then simply waiting for the task to finish. – Haxiel Jan 7 at 13:18
  • 1
    I'm glad to help someone who is genuinely willing to learn :-). Since this is a Q&A site, would you consider adding your workaround as a self-answer to this question? This would be useful to a future reader, and would be generally valuable for the site. Comments are supposed to be temporary, so they end up being removed at some point. – Haxiel Jan 8 at 17:30

Seems like the release-it tool executes the command in a non-interactive mode without stdin or stdout available. My workaround (for future readers who find this post with a similar issue) was to build a simple shell script above release-it, which calls release-it and after successful completion, then calls stencil push

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.