Minify HTML, but don't touch PHP with Gulp : <h2>The problem</h2>

<p>I have a lot of <em>.php</em> files, mostly containing HTML, but also some PHP lines on top (e.g. form trigger code or similar). So they look like</p>

<pre><code>&lt;?php
if($someValue){
    //doSth
}
//more content
?&gt;
&lt;!DOCTYPE html&gt;
&lt;html lang="de"&gt;
&lt;head&gt;
    &lt;title&gt;My Website&lt;/title&gt;
    &lt;meta name="viewport" content="width=device-width, initial-scale=1"&gt;
&lt;/head&gt;

&lt;body&gt;
&lt;!-- Content and scripts here --&gt;
&lt;script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.0/jquery.min.js"&gt;&lt;/script&gt;
&lt;/body&gt;
&lt;/html&gt;
</code></pre>

<hr>

<h2>The goal</h2>

<p>My goal is to <strong>minify</strong> the HTML (and maybe even the inline javascript, but that's just a little extra), without touching the PHP on top.
I'm using Gulp as automated build tool and would like to see a solution using this tool and any extra packages as they are needed.</p>
