Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

3
  • Strange, I have alias svn_diff='svn diff --diff-cmd /usr/bin/diff -x "-i -b" $1' working, where $1 is a file path. I have confirmed this works for the ip_usage. I'm not following the difference between functions and aliases. It seems like the above example uses positional arguments. Commented Nov 17, 2017 at 21:22
  • 1
    @chris85 Yes, that works but only accident because the $1 is at the end of the alias where the arguments you supply would appear (with or without the $1 at the end). Commented Nov 17, 2017 at 21:24
  • 1
    @chris85 Very good. Also, I just added a longer explanation to the answer of how aliases work with $1. Commented Nov 17, 2017 at 21:31