The command-line is the interactive interface to your shell.

learn more… | top users | synonyms (1)

5
votes
2answers
243 views

Combining multiple process substitution

Suppose you tried something like this: $ paste ../data/file-{A,B,C}.dat and realize that you want to sort each file (numerically, let's suppose) before pasting. Then, using process substitution, ...
3
votes
2answers
469 views

Jingle CLI client / Jitsi replacement / VOIP

I am looking for a Jingle client for the command line. Currently, I use Jitsi, but my dreams of not needing the GUI for more than just web-browsing are not realized due to my reliance on this ...
1
vote
1answer
948 views

How to access u boot environment from linux?

How can I access and change the u-Boot env variables in linux. Using the u-boot/tools/env directory in u boot directory: u-boot$ make env Which created the executable file fw_printenv. I copied ...
3
votes
1answer
268 views

Confirm before exit the command-prompt

I am trying to have a confirmation message every time I type exit command in the command-prompt. To do this, I have tried to use trap in .bashrc file but it seem like trap is not a solution as it run ...
-1
votes
1answer
58 views

delete file with name --help.tgz [duplicate]

I have file with name --help.tgz. I want to delete but don't know how. I tried rm "--help.tgz", rm \-\-help.tgz and it did not work. How can I delete a file with such name?
2
votes
1answer
112 views

zsh - check arguments of a command before executing it

Question: Is there an easy way how I can teach zsh to check the command line before executing it? I know that I can completely wrap a specific program with an extra script, but this is not what I want ...
0
votes
4answers
137 views

concatenating multiple files with multiple headers

Im trying to concatenate multiple files with multiple headers to have one file with all the information in it for example. File 1: Numbers 1 2 3 Letters A B C File 2: Numbers 4 5 6 Letters D E ...
2
votes
6answers
1k views

sort ls output by users

On Linux, is there a way to sort ls output by users? What I try to achieve is something like this: user_a   file1 user_a   file2 user_b   another_file user_c   this_file user_c ...
1
vote
2answers
5k views

How to avoid the need to issue “y” several times when removing protected file

I'm looking for a solution to be used as a response to "rm: remove write-protected regular file [x] ?" I was thinking of issuing a character followed by carriage return for several amount of times, ...
5
votes
3answers
3k views

Count number of lines of output from previous program

I'm trying to count the number of lines of output a certain program produces. The problem is, the program takes a long time to run, and I want to display the output to the user. Is there a way to ...
1
vote
0answers
120 views

rsstail Not Printing Output

I've installed rsstail 1.8 on my linux box and everything seems to be going smoothly, knock on wood, except for the part where rsstail isn't printing the streams. Running the command, I see that it's ...
4
votes
3answers
307 views

Why should 'Character Classes' be preferred over 'Character Ranges' In Shell (Bash)?

The Linux Command Line (Book - page count 47) says: ... you have to be very careful with them [character ranges] because they will not produce the expected results unless properly configured. For ...
0
votes
1answer
287 views

finger and who commands usage

I know that the finger command used to display information about local and remote users. finger --> display users log in on local machine, even if remotely. finger @hostname --> display users log in ...
2
votes
1answer
420 views

Alternative to xxd for QNX

I was just introduced to xxd today. See link. I am very familiar with the QNX hd and odcommands, both of which will take input and create a hex dump (or octal dump if you like). See hd and od. What I ...
0
votes
1answer
95 views

(e)grep and atomic grouping [comprehension question]

I am trying to understand the correct use of »atomic grouping« a.k.a. »independent subexpressions« a.k.a. »non-backtracking subpattern« [this are the terms I found ...
1
vote
2answers
1k views

cannot mount .img file - “not a directory” error

I try to execute the following command on an ubuntu 12.04 system: sudo mount minix203.img -o loop -t minix /mnt/myminix/ in order to mount an .img file with minix partition; and get the following ...
1
vote
1answer
324 views

Safely convert unicode strings to printable characters

I have many HTML files containing mixed unicode strings like \303\243 and printable characters like %s. What I'd like to do is converting the unicode strings into printable characters in a safe way. ...
2
votes
2answers
42 views

Start Repl/CLI in Background and Feed Commands

Lets say the python repl takes a long time to start up, is there a way to start it up in the background so I can create an alias and feed it commands like python-current "command to run".
0
votes
2answers
1k views

what is “an invisible whitespace character that takes up space”

One can look up Unicode Characters with Regular Expressions. On Jan Goyvaerts website I found a RegExp whose meaning I don't understand : \p{Zs} or \p{Space_Separator}: a whitespace character that ...
0
votes
2answers
505 views

'df' command doesn't list /home directory

In the book I am reading, the output of df command is shown like this: Filesystem 1K-blocks Used Available Use% Mounted on /dev/sda2 15115452 5012392 9949716 34% / /dev/sda5 59631908 ...
0
votes
1answer
67 views

Syntax of DISPLAY=:0 unity --replace or DISPLAY=:0 compiz --replace

Why don't the commands have a & between the setting of DISPLAY and running unity or compiz. I understand that both work (re-starting unity or compiz), but fail to see why are they the way they ...
0
votes
0answers
163 views

Rsync seems to back up files that haven't been opened or changed

I have started using rsync to back some data on my mac to an external HD. It works really well, but I have noticed something odd. Every time I run the command, I get a list of files that haven't been ...
3
votes
2answers
10k views

what is pts/0 and (:0.0) in linux by type who am i

When I type the command: [root@degeneration Desktop]# who am i root pts/0 2013-04-12 15:08 (:0.0) What is pts/0 and what is meant by (:0.0)?
1
vote
1answer
3k views

Reading from USB serial port under Cygwin

I am actually using Cygwin, but it is my understanding that it responds to Unix commands so hopefully I am in the correct place. I have an Arduino hooked up via USB to my LapTop for data reading. I ...
0
votes
1answer
138 views

How to get the Installation path of binary and logic file in Daemon in Arch Linux

I want to know that if i install a daemon service in Arch Linux, then what will be the path of the files that will get install. also which files will be install where.
0
votes
2answers
41 views

can't update with this error messg

I got this message: not enough free disk space.... The upgrade needs a total of 31.8 M free space on disk '/boot'. Please free at least an additional 31.8 M of disk space on '/boot'. Empty ...
4
votes
2answers
2k views

greedy and lazy regular expressions (comprehension question)

I am teaching myself regular expressions, and I got stuck at »greedy« vs. »lazy« repeatings. What I found out so far is that »greedy« means that the RegExp ...
0
votes
1answer
140 views

from a laptop with CentOS 6.3 what is the command line to talk mysql server on my pc?

I have CentOS 6.3 running on my laptop which is already connected to the net. What is the command line to talk to MySQL server on my PC? Both devices are connected via my router and they can talk ...
1
vote
2answers
184 views

Can't remove same folder name twice

I have a folder called - bin , then I remove it by rm bin , re-create it and when I want to remove it again by rm bin the shell promts - /bin/mv: cannot move `bin/' to ...
2
votes
2answers
3k views

Sending a file as the body of an email

I want a utility that does something like this: email --subject="xxx" --body=body.txt --to=to_address@hostname.com (using pre-configured sender information for e.g. gmail). Note that body.txt is ...
1
vote
2answers
199 views

How to strip directory structure with command line (or script)

I have a large collection of files packed into a two-level directory structure with many, many, many folders. In other words, I have a folder with a great many subfolders in it. There are no ...
2
votes
5answers
289 views

Create and open file with one command?

I want to create a text file and open it in a text editor with a single command. I know touch file.txt creates a file and open file.txt opens the file, but is there a way to do this with a single ...
0
votes
3answers
3k views

Regular Expression for finding double characters in Bash

I am looking for a regular expression that finds all occurences of double characters in a text, a listing, etc. on the command line (Bash). Main Question: Is there a simple way to look for sequences ...
8
votes
3answers
2k views

How do you send command line apps directly to the background?

I already know that pressing ctrl+z stops the app, then I can send the app to background with the bg command, but that means there is a brief preiod of time that the app is stopped. How do I send the ...
3
votes
4answers
1k views

Transparently run wine programs

When I want to run a wine program I have to type e.g. $ wine ~/.wine/drive_c/Program\ Files/TextAloud/TextAloudMP3.exe Would it be possible to run directly TextAloudMP3? I mean not only from command ...
13
votes
6answers
1k views

Can a Linux command have capital letter(s)?

Can a Linux command have capital letter(s)? I know it's supported but i want to be sure if it's a "problem" or considered "not a good thing"?
1
vote
1answer
294 views

Unix Date command not working for few servers

I am trying to execute date command in unix server for yesterday. The commands tried are : date --date ="1 day ago" date --date ="1 days ago" date --date ="yesterday date --date ="-1 day" These ...
7
votes
6answers
9k views

Getting cpu usage same every time.

When I execute following command to get cpu usage , I get nice + user cpu usage. top -b -n1 | grep "Cpu(s)" | awk '{print $2 + $4}' Output: 14.5 Here I am getting problem is that the output ...
2
votes
2answers
257 views

How to target multiple selections with xclip

When copying text to the clipboard, xclip provides several selection targets: -selection specify which X selection to use, options are: "primary" to use XA_PRIMARY (default), ...
1
vote
2answers
827 views

What is the difference between the whatis and apropos commands?

CentOS 6.3 / RHEL 6.3 Can someone please explain the difference between the whatis command and the apropos command? I noticed that both appear to be installed by default and I'm not sure what the ...
7
votes
3answers
8k views

How do I remove all sub-directories from within a directory?

This question is kind of a phase II to the first question I posted at here I have a directory that contains a bunch of sub-directories, .zip files, and other random files not contained within a ...
1
vote
2answers
112 views

Cross Unix Command Reference

I am looking for a website that contains a reference between how to do things on the command line in different unix OSs. I have seen such site before, I am just unable to find it. I know such site ...
8
votes
5answers
246 views

store command before pressing ctrl+c, revive afterwards [duplicate]

Sometimes I type a lengthy command in my command prompt and then notice that I need to check something before actually pressing return and executing the command. I press ctrl+c, execute the new ...
8
votes
1answer
11k views

command to zip multiple directories into individual zip files

I have a single directory that contains dozens of directories inside of it. I'm new to command line and I'm struggling to come up with a command that will zip each sub-directory into a unique ...
1
vote
2answers
821 views

Executable located in location A how to run it in location B?

So, I've an executable in my debian server and this executable located in /home/human/ExecuteIt, still i cant figure it out how to run my executable in another location. In my case it is ...
2
votes
1answer
231 views

Command to list contents if directory, or do output contents if file?

Is there any command to list the contents if passed a directory, but output the contents if it's a file? For example, often when I am navigating the directory structure I will start typing into the ...
5
votes
1answer
5k views

Better way to copy multiple directories to new directory

Is there a better way on the command line to essentially accomplish the following but with a single command cp -r css/ ar/ cp -r images/ ar/ cp -r js/ ar/ cp -r backups/ ar/ I've just been ...
1
vote
1answer
412 views

Slackware Console Resolution when Dual Booting with Another Distro's GRUB2?

I am tweaking my new Linux Installs on a new home-built machine. I installed Linux Mint 14 first followed by Slackware 14 and Arch Linux on separate partitions. I don't think it matters, but the ...
2
votes
1answer
108 views

Chain commands with Control + C interrupt

I am trying to execute a program which loops indefinitely, and so must be forcibly interrupted. After executing the program, I want to delete it. I can do it in several steps: ./MyProg Control + C ...
4
votes
2answers
98 views

Where does the yanked text on commadline get stored?

When you delete characters on the command line using readline commands (e.g. Ctrl-U, you can paste using Ctrl-y, but where does it get stored? It does not seem to use X11 clipboard at all.