# Close slicersalt after processing in commandline

**URL:** <https://discourse.slicer.org/t/close-slicersalt-after-processing-in-commandline/21159>\
**Category:** SlicerSALT\
**Created:** [December 21, 2021, 2:47am UTC](https://discourse.slicer.org/t/close-slicersalt-after-processing-in-commandline/21159 "2021-12-21T02:47:55Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![iPsych](https://avatars.discourse-cdn.com/v4/letter/i/e19b73/32.png) [@iPsych](https://discourse.slicer.org/u/iPsych)\
**Post date:** [December 21, 2021, 2:47am UTC](https://discourse.slicer.org/t/close-slicersalt-after-processing-in-commandline/21159/1 "2021-12-21T02:47:55Z")

</div>

Running slicersalt via commandline seems very useful, but seems not-loop friendly.  
Is it possible to stop slicersalt, after  
./slicersalt --no-main-window --python-script SOME COMMAND?  
after successful run, the cmd stops with ‘all pipeline took ~~~’.

Because this, it’s not loop-able for bash script. Is it possible to kill slicersalt and make commandline script loopable?

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [December 22, 2021, 3:52am UTC](https://discourse.slicer.org/t/close-slicersalt-after-processing-in-commandline/21159/2 "2021-12-22T03:52:56Z")

</div>

You can add `exit()` as the last command or you can use the `--testing` command-line argument (which exits the application when all the commands are executed).
