title: check if argv is a directory
body: <p>I'm using FISH (Friendly Interactive SHell)</p>
  
  <p>and I created 2 functions :</p>
  
  <pre><code>function send
      command cat $argv | nc -l 55555
  end
  </code></pre>
  
  <p>--> send a file via nc</p>
  
  <pre><code>function senddir
      command tar cjf copy.tar $argv; cat copy.tar | nc -l 55555; rm copy.tar
  end
  </code></pre>
  
  <p>--> send a dir by compressing it via nc</p>
  
  <p>Now, I wan't to refactor and create a send function that does both, for this I need to check if argv is a dir. How can I do it with fish?</p>