Reputation
2,935
Top tag
Next privilege 3,000 Rep.
Cast close & reopen votes
Badges
4 16 33
Impact
~250k people reached

May
6
comment Storing shell scripts
Of course, you'll have to make the scripts executable, using something like chmod a+x script1.sh
Apr
22
comment how to disable autofs4
@edwardtorvalds Sorry, no idea. Are you sure this takes 15 seconds?
Mar
19
comment sed - perform multiple substitutions on a line found by pattern search?
This prints two lines for each match. You have to remove the first 'p' action in the first two solutions.
Mar
17
comment Regular expression that ignores certain characters
@mikeserv I thought he wanted to ignore the \" and so on to be able to match e.g. muller with M\"uller.
Mar
16
comment Regular expression that ignores certain characters
@User133713 Could you clarify what the process is you are working on? Please edit your question...
Mar
16
comment Regular expression that ignores certain characters
Can you give an example of how you want to use the bib2bib tool?
Mar
11
comment Moving LXC container's backing storage
Can't you make /var/lib/lxc a symbolic link to a directory in /home?
Mar
11
comment Combining, sorting and deleting duplicates in numerous gzip files
The man page says that that the default is the number of processors. But a quick test sorting a few log files suggests that giving the parameter does make things faster. So: yes, use that parameter!
Mar
11
comment Combining, sorting and deleting duplicates in numerous gzip files
The merge command does something completely different; sort -m is the way to go. As to how to unzip: I don't think it matters much, as long as you don't start more than 2 processes per file: one to decompress, one to sort.
Mar
4
comment Syntax highlighting and export EPUB format
@MohsenPahlevanzadeh Could you please clarify what is meant by "RTL"? Is this right-to-left?
Mar
4
comment Syntax highlighting and export EPUB format
Did you mean the RTF file format?
Feb
19
comment What is a best practice to represent a boolean value in a shell script?
The dummy string for the if test is not necessary if the variable is quoted; if [ "$variable" = "yes" ] works fine even if $variable is not set.
Dec
9
comment Script thinks input is a command?
Put a space between the [ and the following text. This ought to fix it
Nov
5
comment Modify a file without creating another file
The vi and sponge solutions also create temporary files to do their work...
Oct
20
comment Shell script written in a different shell than what my current shell
The only thing I would add is if you execute the script using . script.sh or source script.sh, it will use your current shell, not spawn a new one. Which means that then it will make a difference what shell you are using.
Aug
26
comment Login by ssh , exec one command and i don't want to quit the bash
I achieved the same by changing the PS1 setting in the .bashrc of all remote machines I was working on (30+ servers). This means some setup work, but then you can just ssh into the machines..
Aug
18
comment Why doesn't the sudo command need the root password?
The answer should really start with the setuid part, because that's the reason that it is actually possible. /etc/sudoers is just the reason for the flexibility of the sudo command.
Aug
4
comment Why am I getting “Job for httpd.service failed…,” and how do I go about fixing it?
What happens when you start apache directly with /usr/bin/apachectl start?
Jul
31
comment two if conditions in for loop bash scripting
Your netstat line does not use the $i value at all. So either you'll get the "NOT - OK" line three times, or not at all.
Jun
1
comment Is it possible to inject newlines in the ouput of cowsay/cowthink while preserving the “bubble”?
No, what comes on the command line is not stdin.