Questions about using the command-line interface (CLI).

learn more… | top users | synonyms (5)

21
votes
2answers
14k views

How to edit pdf metadata from command line?

I need a command line tool for editing metadata of pdf-files. I'm using a Aiptek MyNote Premium tablet for writing my notes and minutes on this device, import them later and convert them to pdf ...
21
votes
2answers
1k views

Does using -v (verbose) slow commands down?

In this question: How to remove all files and subdirectories in a directory WITHOUT deleting the directory in bash? it is asked how to delete all file in a folder, and not the folder itself. Matts ...
21
votes
3answers
5k views

What is the maximum length of command line arguments in gnome-terminal?

What is the maximum length of command line arguments in gnome-terminal? ... and is there a system environment variable which reports this value?
21
votes
6answers
20k views

Can I use NetworkManager without a tray/dock/bar?

I would like to use NetworkManager, but prefer a keyboard driven window manager that provides as much space on the screen as possible for my code. I just hate that little strip of real estate "trays" ...
21
votes
3answers
196k views

How to start GUI from command line?

I've installed the following version of ubuntu om my machine. ubuntu-12.04-desktop-i386.iso But when I switch on the computer, I get command line. Ubuntu 12.04 LTS COMP-1245 tty1 Once I ...
21
votes
2answers
25k views

How do I extract a password protected .7z file?

Can someone tell me how can I extract a password protected .7z file in Ubuntu server? (I know the password, I just need a program to do so and an example of how to use said program...)
21
votes
1answer
5k views

How do I pipe terminal standard output (stdout) to the clipboard?

For example, Say I want to list the contents of a folder and directly paste them into a chat window for a friend to see. I realize I could do ls > filename.txt to create a file (filename.txt) ...
21
votes
1answer
40k views

How do I change the language via a terminal?

Using system settings I changed my language to Arabic and deleted the English language from the settings. Then the computer lagged and it logged out - now I can't log back in because the login is in ...
20
votes
8answers
60k views

How to move multiple files at once to a specific destination directory?

I got a bunch of files in some directory (along with many other files) that I want to move. Luckily, all the files I want to move contain a certain identifier in their names, so I can ls | grep ...
20
votes
5answers
49k views

How can I make a script that opens terminal windows and executes commands in them?

I have three scripts I need to run when I start up my Ubuntu machine, they start services I use in my development environment. To do that, I manually open three terminals and type in the commands. ...
20
votes
3answers
2k views

Ctrl+L in terminal

I accidentally typed ctrl + L in terminal and my terminal window jumped one 'screenful' size. I looked at the keyboard shortcuts in "Edit"->"Keyboard shortcuts" and didn't find that shortcut. What ...
20
votes
6answers
58k views

How to close vim from the command line?

I know this is more of a general linux question but w/e. So when I enter a program like vim in the command prompt it displays all the text in the file and I can edit it etc. But I can't figure out how ...
20
votes
3answers
27k views

Why does “ps aux | grep x” give better results than “pgrep x”?

I've just tried the following command on my Ubuntu, it doesn't show a thing: pgrep php5 shouldn't it return the process id of php5(which the following command just does)?: ps aux | grep php5 So, ...
20
votes
2answers
11k views

What do the various dpkg flags like 'ii' 'rc' mean?

I frequently need to check which packages are installed, and I use the following command: dpkg -l | grep foo which gives the following output Desired=Unknown/Install/Remove/Purge/Hold | ...
20
votes
10answers
14k views

Command line audio players

What are popular audio players for the command line? How to play a single sound file? Are there command line players that also index the music library like Banshee, Exaile, etc.?
20
votes
3answers
15k views

Bash history handling with multiple terminals

I use mainly Terminator, and it's usually opened with 3 split terminal windows. I also use Gnome terminal for various reasons. I'm wondering how is bash history handled in this case as I sometimes ...
20
votes
3answers
3k views

Where can I find the command line?

A basic question: Where do I find the command line? There is a lot of information about commands and using the command line, but I'm an absolutely new Ubuntu user: I can't find find the command line. ...
20
votes
1answer
224k views

How to copy files via terminal?

I have read about copying files with terminal but these examples will help me a lot. So here is what I want to do: Examples: I have a file in /home/levan/kdenlive untitelds.mpg and I want to copy ...
20
votes
4answers
3k views

What do “.” and “..” mean when in a folder?

when I used ls -a to view hidden files in folder there were 2 hidden files created by default what is the significance of this two files . and ..? ls -a Produces . ..
20
votes
2answers
15k views

How do I disable the blank console “screensaver” on Ubuntu Server?

How to disable blank screensaver on Ubuntu Server? There's no desktop or X, only console (command-line interface).
19
votes
5answers
2k views

How to both display a command line's output on console and save the output into a text file?

How can I run sudo apt-get install by BOTH seeing the process of installation (long in my case) and saving its output into a text file ?
19
votes
5answers
2k views

Unable to remove a file which has a name like a command argument [duplicate]

I inadvertently created a file called -r in my home directory. Now I cannot get rid of it: rm -rf rm: missing operand Try 'rm --help' for more information. Other attempts: rm /-/r rm: cannot ...
19
votes
2answers
2k views

Why I can find *main.o but cannot *.o?

This one is correct: $ find . -name *main.o ./main.o So, why I can't find *.o? $ find . -name *.o find: paths must precede expression: main.o Usage: find [-H] [-L] [-P] [-Olevel] [-D ...
19
votes
8answers
46k views

How to remove all files and subdirectories in a directory WITHOUT deleting the directory in bash?

Is there a command to remove all files and subdirectories in a directory WITHOUT deleting the directory? For example if I have directory "dontDeleteMe" with subdirectories "1", "2", "3" and each ...
19
votes
4answers
19k views

How to add Android Studio to the launcher?

I'm trying to install the android studio so that I can launch it from a launcher instead of via terminal. Can someone give specific instructions please? I think this is something to do with the ...
19
votes
6answers
14k views

Command to see media file info in terminal?

I need a command to quickly see in terminal essential information about an audio or video file. (Then I'll consider adding that to Thunar's custom actions, etc.)
19
votes
2answers
1k views

How do I run an application with arguments from the command line without losing the terminal?

I use dwm as a window manager on Ubuntu, I like tiled windows and I like them as few as possible. I sometimes need to run an application (let's say it's the pdf viewer mupdf in x11) from the terminal, ...
19
votes
3answers
8k views

How to show ascii art at the top of the terminal when it's opened?

As you can see on this screeshot of Mik's Guake he have a statup message of ascii art when he opens it, and that's what I'd like to do, can someone help me?
19
votes
3answers
17k views

How can I convert a ppt to a pdf from the command line?

I have a folder containing a bunch of ppts, each of which I'd like to convert to an individual pdf. I'm using Ubuntu 10.04 with whatever comes installed on it.
19
votes
3answers
115k views

find a file using the terminal

I am trying to find a directory, using the terminal and I am not sure where it is. I mean that i used the wget command to obtain the file and used it for installation and now i am not able to find ...
19
votes
2answers
823 views

Why does it take so long for Ubuntu to say “command not found”

For some reason, with my setup, it can take Ubuntu several seconds to respond with "command not found" when I accidentally typo a command. Why does it take so long? Is there any way to shorten the ...
19
votes
5answers
931 views

What are shells?

What's a shell, their importance, types and functions?
19
votes
2answers
4k views

How does this [t]ricky bracket expression in grep work?

I saw this one-liner recently: $ ps -ef | grep [f]irefox thorsen 16730 1 1 Jun19 ? 00:27:27 /usr/lib/firefox/firefox ... So it seems to return the list of processes with "firefox" ...
19
votes
3answers
1k views

iPython Like Command History For Shell

For those of you who don't do python programming on ubuntu, ipython is a python shell on steroids, but it has this amazing feature that it not only autcompletes based on known names (i.e. the same way ...
19
votes
3answers
3k views

How do I search a PDF file from command line?

I'm checking references of a paper and want to find the positions in the body where some paper (in the references list) is referenced. Is there a PDF editor which supports search via bash and extract ...
19
votes
8answers
21k views

How does one find out the command line corresponding to GUI app (eg, LibreOffice Writer)?

How can I run LibreOffice Writer from the command line? Basically, what is its command and how do I get to know what's the command to run a particular application in general?
19
votes
2answers
2k views

How to change number of workspaces from command line?

I'd like to change org.compiz.profiles.unity.plugins.core -> hsize and -> vsize from command line. I thought I could use gsettings set org.compiz.profiles.unity.plugins.core vsize 4 but then ...
19
votes
3answers
4k views

“♦: command not found” in tty after login

I have this problem after upgrade Lubuntu from 12.10 to 13.04. I press Ctrl + Alt + 1, enter login, password, wait two seconds and get: ♦: command not found". After this message I can type commands ...
19
votes
1answer
15k views

How can I find out what RAM a computer system has?

I'm looking for a way to find out what kind of RAM a system has (clocking speed, DDR-X etc.). Is there a specific command for that? I'm only aware of free or lspci which don't offer those things.
19
votes
4answers
2k views

CLI mounting vs. GUI mounting

On Ubuntu 12.10, when I want to mount a hard drive, I can just click on the unmounted drive and everything works fine (by mounting to /media/username/partitionlabel). Basically, I would like to do ...
19
votes
7answers
14k views

How do I toggle sound with amixer?

Including Natty I was always able to toggle (mute/unmute) the 'Master' sound volume with the amixer sset Master toggle command that I linked to an edge binding in CompizConfig-Manager. Now after ...
19
votes
2answers
3k views

How does Middle Click paste work?

I don't understand the middle click paste. Sometimes I highlight text, middle click in the window where I want it to go and it does what I want. Sometimes it doesn't. For instance, when I highlight ...
19
votes
2answers
8k views

What does “%U” mean when calling a command?

When editing the Applications menu, I see for some applications, their commands have “%U” such as "gedit %U" and "gnome-mplayer %U", but others don't such as "gcalctool". I was wondering What“%U” ...
19
votes
3answers
721 views

Saving output of a grep into a file with colors

I need to save the result of a grep command into a file, but I also want the output file to be formatted and keep the colors just like in the terminal. Is there a way to do that? Maybe make grep save ...
19
votes
4answers
19k views

How do I burn a DVD ISO using the terminal?

I have a DVD ISO file and i want to burn through the terminal . We have many command formats but i am unable to choose the best & safe one . so please give me a best command to burn the ISO ...
19
votes
3answers
4k views

How to find the number of packages needing update from the command line?

I'm working on some system admin automation using fabric and I'd like to be able to monitor the number of packages that need upgrading on a given machine. This is the same information that I can see ...
18
votes
5answers
7k views

How to open a file manager of the current directory in the terminal?

When I work in terminal, sometimes I want to open the current directory in a GUI file manager. And then to click the items in the window to run the application. How can I do this?
18
votes
4answers
15k views

How do I download the command-line emacs instead of the GUI one?

I used sudo apt-get install emacs to download emacs. I expected the command-line emacs to start when I ran emacs but instead the GUI emacs started. How can I download the command-line emacs?
18
votes
4answers
31k views

Where to declare environment variables?

What are correct places for: Global environment variables meant to affect all users? User-specific environment variables?
18
votes
2answers
1k views

is there any significance to using tee

Why is it that almost all instructions regarding appending text to system files like fstab and /etc/apt/sources.list.d/<name>.list involve using tee and echo to append said text? Take the ...