19,557 reputation
34173
bio website
location United States
age
visits member for 3 years, 1 month
seen 9 hours ago

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


Aug
7
comment Why is “shebang” called “shebang”?
@Tim shb is not really a natural-sounding consonant in English, so some vowel is required to separate the sh from the b.
Aug
7
comment Fork call and recursion
@terdon "any code that contains fork is by definition one that will only run on *nix" - There may be rare exceptions or corner cases I am unaware of, but this is the general rule.
Aug
7
comment Fork call and recursion
@terdon You could argue programming questions are off-topic, but you can't really say fork is "purely C" since it is a system call primarily associated with *nix and POSIX operating systems, with behavior that happens to "break" the normal rules of "pure" C. You won't find any mention of "fork" in the C standard.
Aug
6
comment What are some preferred methods to efficiently edit files on a remote Unix server?
No worries. Vim has a bit of a steep learning curve to turn it from a crappy console Notepad to a real power tool. Not everyone likes it but I would really recommend going through some of the basics so you at least have an idea of what it is capable of.
Aug
6
comment What are some preferred methods to efficiently edit files on a remote Unix server?
My preferred method is simply sudoedit over ssh.
Aug
6
comment What are some preferred methods to efficiently edit files on a remote Unix server?
"vim, [...] which of course limit your cursor to navigate one character at a time with very limited cut/copy/paste capabilities." -- I would recommend running vimtutor and going through it on your local machine. It should take 30 minutes or less. Your statement shows that you clearly have no idea what vim can do.
Aug
6
comment Is space not allowed in a filename?
@snailboat Spaces are a symptom of the real problem which is a lack of standardization. Unix filesystems allow file "names" to nearly unrestricted binary blobs. The only illegal bytes are 0 and 47 (the / separator). Using all 254 remaining bytes opens the door to all manners of unspeakable eldritch "names". Obviously this is insane, but not everyone agrees on what "sane" is, and different characters will break different tools. The intersection of everyone's sanity is quite small.
Aug
6
comment Store output of a command into a ring-buffer
@PeterMortensen Wikipedia:Gibibyte
Aug
5
comment How to customize Bash command completion?
Have you considered simply aliasing loc to localc? I suggest alternatives because after quite some time digging and searching I have not found a way to customize bash completion this way. It may not be possible.
Aug
5
comment Run a script on multiple shells?
If AIX commands and Linux commands are very similar, it may make sense to put them in the same script with some extra code to handle the differences. If AIX commands and Linux commands are completely different, it may make more sense to have two different versions of the script.
Aug
5
comment Is a ? treated in a special way in parameter expansion?
@Bernhard "Don't source unless you explicitly want to" is good advice. For example, sourcing the above snippet sets IFS, an important variable that affects other aspects of shell operation, to a non-default value. In this case however, it doesn't affect OP's question, but I would recommend putting IFS back anyways.
Aug
5
answered Is a ? treated in a special way in parameter expansion?
Aug
3
comment What is a command that will only show me the command syntax and options?
whatis will give you output that is basically the first line of the corresponding man page, but that typically does not contain any option synopsis.
Aug
2
awarded  Yearling
Aug
1
comment scp to an alias
@ryekayo Aliases do not work this way, so restarting wouldn't help.
Jul
30
awarded  Nice Answer
Jul
29
comment replace comma in specific column value
Judging by your sample input you could just delete all commas everywhere with tr -d , < file.txt > output
Jul
29
comment Piping the output of ls or tree to less loses colors?
@Tim 2 reasons: 1. less removes the colors by default unless you give it the -R option, which tells it to leave it in, and 2. tree and ls and other programs usually turn coloring off when they detect their output is going to another program (like less) instead of directly to your terminal, unless you force the coloring on with -C or --color=always.
Jul
22
awarded  Nice Answer
Jul
11
comment Symbolic link permission changes
I don't think you can change it. The permissions on a symbolic link don't matter, and are always displayed as 777. Only the permissions on the file it points to matters.