Reputation
Top tag
Next privilege 125 Rep.
Vote down
Badges
3
Newest
 Student
Impact
~59 people reached

  • 0 posts edited
  • 0 helpful flags
  • 70 votes cast
Mar
29
awarded  Student
Mar
28
awarded  Commentator
Mar
28
comment How do I remove the current directory (“.”) from my PATH?
While I agree that it's clearly not a bug, I'm not sure that just because it's the default makes it desirable. I don't want that to be the default, because having . in your path is potentially dangerous. A much more sensible default would be to simple ignore blank directory names.
Mar
28
answered How do I remove the current directory (“.”) from my PATH?
Mar
28
comment How do I remove the current directory (“.”) from my PATH?
@Law29 That was it! Bash was treating the duplicated colons as if they indicated that . should be in my PATH. I can't imagine why, though...
Mar
28
comment How do I remove the current directory (“.”) from my PATH?
@FrankThomas Your OSs have been dangerously misconfigured, then. Having . in your path leaves you open to malicious code running without your knowledge. Someone could stick a script into your working directory called sudo, and any time you used sudo, you'd unknowingly be giving your password to that script, instead of the real /usr/bin/sudo command. Not having . in your path means that when you want to execute something in your current directory, you have to acknowledge that by using ./command instead of command. Also, your second comment about $PATH evaluation is simply wrong.
Mar
28
asked How do I remove the current directory (“.”) from my PATH?
Mar
28
suggested rejected edit on Where does $PATH get set in OS X 10.6 Snow Leopard?
Jul
30
comment Set the title of the terminal window to the current directory
@MattTagg Sure, you just need to put it into your ~/.profile (or equivalent) file on the remote machine.
Dec
12
comment How do you prevent the dock from switching monitors in OSX Mavericks?
This is best answer for people who don't care about the dock. I use QuickSilver, and thus have no need for the dock. But having it semi-randomly jump all over the place was extremely annoying. Now it's nice and hidden away on the left side of my monitor group, and won't be going anywhere.
Sep
18
comment Does bash have a hook that is run before executing a command?
@cYrus Thanks! I don't know nearly enough bash programming to have noticed that problem.
Sep
16
comment Does bash have a hook that is run before executing a command?
I used a combination of this answer with some of the special stuff in the accepted answer: trap '[ -n "$COMP_LINE" ] && [ "$BASH_COMMAND" != "$PROMPT_COMMAND" ] && date "+%X";echo -e "\e]0;$BASH_COMMAND\007"' DEBUG. This puts the command into the title and also prints the current time right before every command, but doesn't do so when executing $PROMPT_COMMAND.
Dec
5
comment Cut and Paste in Mac OS X's Finder
In Windows, "cutting" a file doesn't actually remove it from its original location until you paste it somewhere else. The file explorer fades the icon to indicate that it's been "cut", but if you put something else on the clipboard, the icon fades back in.
Dec
4
comment Cut and Paste in Mac OS X's Finder
Because being forced to use such a complicated mouse gesture, when other operating systems allow this operation with a simple pair of hotkeys, is ridiculous.
Dec
4
comment Cut and Paste in Mac OS X's Finder
@slhck While it is finally possible to move files entirely with hotkeys, it doesn't work in quite the way a Windows user would expect Cut/Paste to function. Rather than Cmd-X -> Cmd-V, the command is now Cmd-C -> Cmd-Opt-V. That will move the Cmd-C'd file to the new destination.
May
23
awarded  Supporter