title: How to automatically update a PDF viewed on the right whenever the corresponding EPS is changed on the left?
body: <p>I am using Visual Studio Code to learn PostScript language.</p>
  <p><a href="https://i.stack.imgur.com/S0eWe.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/S0eWe.png" alt="enter image description here" /></a></p>
  <p>I use the following <code>task.json</code> to convert EPS to PDF.</p>
  <pre class="lang-json prettyprint-override"><code>{
      &quot;version&quot;: &quot;2.0.0&quot;,
      &quot;tasks&quot;: [
          {
              &quot;label&quot;: &quot;EPS&quot;,
              &quot;command&quot;: &quot;ps2pdf&quot;,
              &quot;args&quot;: [
                  &quot;${file}&quot;
              ],
              &quot;options&quot;: {
                  &quot;cwd&quot;: &quot;${fileDirname}&quot;
              },
              &quot;group&quot;: {
                  &quot;kind&quot;: &quot;build&quot;,
                  &quot;isDefault&quot;: true
              }
          }
      ]
  }
  </code></pre>
  <p>And my EPS is</p>
  <pre><code>%!PS-Adobe-3.0 EPSF-3.0
  %%BoundingBox: 10 10 300 300
  
  %%BeginProlog
  /inch {72 mul} def
  /cm {2.54 div inch} def
  %%EndProlog
  
  
  newpath
      1 cm 1 cm moveto
      9 cm 0 cm rlineto
      0 cm  9 cm rlineto
      -9 cm 0 cm rlineto
      9 cm 9 cm rlineto
  closepath
  5 setlinewidth
  stroke
  showpage
  %%EOF
  </code></pre>
  <h1 id="question-jzdn">Question</h1>
  <p>How to automatically update a PDF viewed on the right whenever the corresponding EPS is changed on the left?</p>