19,077 reputation
23972
bio website
location United States
age
visits member for 3 years
seen 26 mins ago

Debian user, GNU/Linux enthusiast, FLOSS supporter, hobby developer.


Jan
1
comment Capture user input while doing other things
@Tyilo If you are going to switch [ to bash syntax [[, change the #!/bin/sh line to bash as well. Otherwise you can do [ -n "$pid" ] && [ false = "$done" ] in plain sh and it should work.
Jan
1
comment display login window as list of users
If you are using GDM (that screenshot looks a bit like GDM), go into the gdm settings, e.g. with gdmsetup, and enable the face list browser or whatever it is called.
Dec
31
comment Will Linux become UNIX, instead of just UNIX Like?
Since this answer is almost word for word the same as the accepted answer for the cited question, if it gets accepted wouldn't that make a very convincing argument for closing the question as a duplicate? I don't think it helps to have duplicate answers scattered all over. Should this be discussed on meta?
Dec
29
comment How to make “notify-send” work from daemon application
notify-send uses DBus, so you'll probably need to set the DBUS_SESSION_BUS_ADDRESS environment variable as well.
Dec
29
comment Is there a shortcut in bash to delete the last segment of a path?
I usually just hit M-Backspace repeatedly until desired effect is reached.
Dec
28
comment Customize the way stderr is appended to a file
On an unrelated note, assuming that you want stdout and stderr to go to the same place, you should remember that stdout is usually buffered whereas stderr is not, which means stderr will almost always arrive before stdout if both go to the same place.
Dec
28
comment Customize the way stderr is appended to a file
You have two different files: status and error and your two examples don't agree on what output goes where. Can you describe exactly what you want to do?
Dec
28
comment Multiple Command List After Shell Conditionals, &&, ||. Shell Script, Dash
After seeing this question and an earlier one of yours, I have to wonder what exactly your idea of "readability" is :P. I tend to agree with @Gilles' opinion that if; then; fi is the most readable way to do this.
Dec
28
comment Restore /etc/ configuration files from the default
purge certainly works for many packages but not the essential ones that you can't remove without seriously breaking things.
Dec
27
comment tmux vs. GNU Screen
Does vi or emacs keybindings just mean tmux comes with a two convenient sets of defaults? It is possible to completely reconfigure screen's keybindings with its rc file.
Dec
26
comment How to move 100 files from a folder containing thousands?
@perer Just as a note that the read -d option is not portable to all shells, but if you are using bash anyways, -d '' should get you the same effect as -d $'\0'.
Dec
26
comment How do I delete a file whose name begins with “-” (hyphen a.k.a. dash or minus)?
This method always works even for commands that don't treat -- specially.
Dec
26
comment How do I delete a file whose name begins with “-” (hyphen a.k.a. dash or minus)?
@lesmana irony indeed :D. I think there is a good lesson to be learned here (read the help - it may indeed be helpful).
Dec
26
comment How do I delete a file whose name begins with “-” (hyphen a.k.a. dash or minus)?
Making a copy of the file is not a very efficient solution for renaming it.
Dec
26
comment How do I delete a file whose name begins with “-” (hyphen a.k.a. dash or minus)?
@KeithThompson find prefixes the command line argument path to all files, so it would run rm ./--help and rm ./sub/dirs/--help. To fix the second, one would have to add -maxdepth 1, but all of this is essentially applying @edfuh's solution in a more roundabout, convoluted way, and -delete is safer than -exec rm anyways.
Dec
26
comment Remap bash vi keys?
Take a look at the bind built-in command in bash, or if you want the changes to be uniform across all readline apps, modify ~/.inputrc.
Dec
26
comment How to do block selection in `screen`
Well, if you ever find it, update your answer and I'll give you an upvote myself.
Dec
26
comment Output of which command used for input to cd
@EliahKagan I think @glennjackman's point was not that backticks don't work, but that they should be gradually phased out in favor of $() due to the many advantages of $() over backticks.
Dec
26
comment How to output only given chars?
It may help future readers if you could edit/clarify your question to state whether you are working with shell variables or text I/O streams. Given the answer you chose to accept, it seems you were looking for the former but that is not entirely clear from the question.
Dec
26
comment How to do block selection in `screen`
I wasn't the downvoter but I imagine the reason was because this answer does not address the question of how to do block-wise selection, which is the reason I felt the need to post a 2nd answer in the first place.