<div dir="ltr">Somewhat related: If you&#39;ve ever traced an ancient UNIX or Linux script, you&#39;d likely see a single colon on the first line instead of a shebang - this is a shortcut to the true function and guarantees that the script will run in the current shell, no matter what the calling shell is (e.g., if you&#39;re in zsh and you run &quot;bash script1.sh&quot;, it would still run in zsh if the script started with a &quot;:&quot; line). It&#39;s one of those things that are incredibly useful the few times you need it (and I&#39;ve used it many times over the years).</div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">On Sun, 31 Aug 2025 at 01:59, Ron &lt;<a href="mailto:ron@bclug.ca">ron@bclug.ca</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br>
It&#39;s a long weekend, a good time to play in the garden, ride bicycles up <br>
and down hills, and watch some `bash` videos.<br>
<br>
<br>
Dave at YSAP discusses &quot;shebang&quot; lines and does his deep-dive into them.<br>
<br>
<br>
Shebang lines are those lines at the top of a script that bash <br>
processes, right?<br>
<br>
Wrong. Bash ignores that line, it&#39;s the kernel that processes the shebang.<br>
<br>
Node / v8 also are smart enough to ignore the shebang line, even though <br>
lines starting with # in JS are *not* comments.  Cool!<br>
<br>
<br>
<br>
He compares behaviours on Darwin, Void Linux, and IllumOS / SunOS.<br>
<br>
Differences show up when passing options in shebang lines.<br>
<br>
<br>
<br>
Lots of interesting tricks can be had by tweaking that line, and after <br>
some 10 minutes of general explanation, he heads down the rabbit hole <br>
starting with his favourite distro, Void Linux.<br>
<br>
<br>
&gt; <a href="https://www.youtube.com/watch?v=aoHMiCzqCNw" rel="noreferrer" target="_blank">https://www.youtube.com/watch?v=aoHMiCzqCNw</a><br>
<br>
<br>
TL;DR:<br>
<br>
use:<br>
<br>
#!/usr/bin/env bash<br>
<br>
(or, since I&#39;m a new convert)<br>
<br>
#!/usr/bin/env fish<br>
<br>
<br>
_______________________________________________<br>
kwlug-disc mailing list<br>
To unsubscribe, send an email to <a href="mailto:kwlug-disc-leave@kwlug.org" target="_blank">kwlug-disc-leave@kwlug.org</a><br>
with the subject &quot;unsubscribe&quot;, or email<br>
<a href="mailto:kwlug-disc-owner@kwlug.org" target="_blank">kwlug-disc-owner@kwlug.org</a> to contact a human being.<br>
</blockquote></div>