title: How to command substitution map in fish shell
body: <p>I would like to be able to do this:</p>
  <pre><code>bat misc | rg -v -e 'TXT|txt' | map path_explode
  </code></pre>
  <p>where</p>
  <pre class="lang-sh prettyprint-override"><code>function map
     while read line       
        command $argv $line 
     end
  end
  </code></pre>
  <p>and</p>
  <pre class="lang-sh prettyprint-override"><code>function path_explode --description 'Return filename, ext, and directory from the path'
      echo $argv[1] | sed 's/\(.*\)\/\(.*\)\.\(.*\)$/\2\n\3\n\1/'
  end
  </code></pre>
  <p>does that make sense? I get this error:</p>
  <pre><code>fish: Unknown command: path_explode
  fish: 
  command $argv $line 
          ^
  in function 'map' with arguments 'path_explode'
  </code></pre>