title: Run command after spawning Poetry Shell
body: <p>I work with Python Poetry and need to automate the process. Specifically, everytime I need to go to a directory with</p>
  <pre class="lang-sh prettyprint-override"><code>cd /work/directory
  </code></pre>
  <p>And spawn a poetry shell with</p>
  <pre class="lang-sh prettyprint-override"><code>poetry shell
  </code></pre>
  <p>and again go to another directory</p>
  <pre class="lang-sh prettyprint-override"><code>cd /other/directory
  </code></pre>
  <p>to finish the work.</p>
  <p>I would love to automate this with a small script like</p>
  <pre class="lang-sh prettyprint-override"><code>#!/bin/bash
  
  cd /work/directory
  poetry shell
  cd /other/directory
  # do work
  </code></pre>
  <p>However whenever I run this script, I get stucks at <code>poetry shell</code>. Is there any option like bash's <code>-c</code> so that I can do following?</p>
  <pre class="lang-sh prettyprint-override"><code>poetry shell -c &quot;cd /other/directory &amp;&amp; do work&quot;
  </code></pre>