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*

11
  • 15
    su -- is the same as su. Commented Feb 7, 2011 at 20:08
  • 15
    -- is a flag that most programs interpret as "nothing after this should be taken as a flag". Useful for greping for things which start with a dash. Commented Feb 9, 2011 at 4:43
  • 3
    Don't forget to set an umask like 000 or it won't work. Commented Oct 22, 2011 at 8:48
  • 14
    One could as well just put a su file inside the PATH. It's not so hard to mimic the behavior of the real su. The super-user has been careless anyway :-) Commented Feb 28, 2012 at 18:53
  • 13
    su -- is NOT the same as su - : -- tells an getopt(s) (or similar) option handler to stop processing the command line for further options (usefull for example if the rest contains filenames which could start with an '-'). Ie, in "rm -i -- -f" : -f is then treated as a regular argument, so here as the name of the file to rm -i, and not as an additionnal -foption to the rm command. So su -- is just su and not su - ! So su -- would be as unsafe to the (funny and instructive) example givan by wag. Use su -. Commented Dec 26, 2012 at 15:05