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

learn more… | top users | synonyms (5)

6
votes
1answer
298 views

How can I run a command and copy its output?

I've been asked to run a command and copy and paste the output but I have no idea where to start. What do I do?
23
votes
2answers
4k views

What does `~/ ` mean?

I'm new to Linux and Ubuntu. People keep using ~/filename in their answers to my questions. What does ~/ mean?
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. ...
10
votes
4answers
7k views

How do I get the version of an application from the command line?

I would like to know how to get the version information of an installed program that doesn't have the --version or -version method implemented.
4
votes
5answers
7k views

What is a full path name?

I would like to understand what full path name really means. I have a file in my home directory called my_script. I assumed the full path name is ./my_script, meaning that it is in the root folder, ...
8
votes
5answers
6k views

Home directory not being created

I am trying to understand system administration on Ubuntu. So, as an example, I create a dummy user using sudo useradd -d /home/linda linda and the passwd to create a the password. I check that an ...
2
votes
3answers
3k views

How to rename multiple files sequentially from command line?

How to rename file as below AS1100801000002.RAW7AGS AS1100801001008.RAW7AH4 AS1100801002001.RAW7AH9 AS1100801003002.RAW7AHE AS1100801004009.RAW7AHT AS1100801005002.RAW7AHY AS1100801010002.RAW7AJ3 ...
2
votes
1answer
5k views

Remove titlebar from maximized terminal window

I'm using XFCE on 10.10 and this is just one of those "is this even possible" type questions. When I have the terminal maximized, is it possible to remove the titlebar, including the close, minimize ...
2
votes
5answers
6k views

How to batch rename files with “variables”? [duplicate]

I use xmbc to view my tv shows. Before I began using xmbc, I batch downloaded the first few seasons of "Bleach". What can I say, I'm an anime fan ;-). These are named: "bleachxx.mp4" where xx is the ...
77
votes
20answers
8k views

Are there any games which can train people to learn terminal commands? [closed]

It seems to me learning how to use the terminal is a prerequisite to learning how to use Ubuntu. So I'm trying to figure out the best way to learn. Is there a Quizlet online flash card set out there? ...
76
votes
7answers
259k views

How to use “grep” command to find text including subdirectories

I want to find all files which contain a specific string of text. The grep command works, but I don't know how to use it for every directory (I can only do it for my current directory). I tried ...
45
votes
5answers
24k views

What is the equivalent of Windows System Properties or Device Manager?

I am new to Ubuntu. In Windows, if I want to know my system properties/configuration, I can see it by going to Control Panel and clicking on the System icon. I can also get a detailed list of the ...
40
votes
4answers
47k views

Find and replace text within a file using commands

How can I find and replace specific words in a text file using command line?
55
votes
4answers
42k views

How can I get octal file permissions from command line?

There is a chmod command to set file permissions, but can I get file permissions in octal mode (such as 755) from the command line?
49
votes
8answers
45k views

Torrent client for the command-line?

Yesterday one of my friends asked me, if there is some torrent client, that runs on the command-line. I have no answer for him, but I think that you have it.
19
votes
3answers
36k views

How to download an MP3 track from a YouTube video [duplicate]

Possible Duplicate: How to download a youtube video via terminal There are several Q&A threads that explain how to download youtube videos using the terminal. However, I would also ...
20
votes
6answers
6k views

How can I create an alias for cd and ls?

I frequently run the ls command after running the cd command. How can I create an alias (like cs) for this operation?
19
votes
3answers
6k 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?
26
votes
2answers
14k views

How can I tell if my system was booted as EFI/UEFI or BIOS?

How do I determine whether a particular running Ubuntu system was booted using EFI/UEFI, or BIOS?
14
votes
4answers
28k views

Where to declare environment variables?

What are correct places for: Global environment variables meant to affect all users? User-specific environment variables?
22
votes
1answer
20k views

What's the difference between ddrescue, gddrescue, and dd_rescue?

The dd command is commonly used to make image backups of a drive or partition. However, it performs poorly if the source drive is unreliable or failing. I read that ddrescue/dd_rescue is a good tool ...
17
votes
7answers
40k views

Create USB installer from the command line?

I'm trying to create a bootable USB image to install Ubuntu on a new computer. I have done this before following the "create USB drive" instructions for Ubuntu desktop, but I don't have an Ubuntu ...
14
votes
3answers
3k views

How to turn off the display via the command line?

Is there a way to turn off the display (enter power saving mode) using a command? For example, when the computer is inactive for a specific interval, the screen turns off to conserve energy. Is there ...
10
votes
2answers
2k views

How to access gvfs mounts from command line?

I have some samba share mounted via Nautilus and I'd like to access the files from command line. They used to appear under $HOME/.gvfs but not any more. Where have they gone to?
13
votes
7answers
12k views

How can I start gnome-terminal at a particular directory?

I've tried gnome-terminal -x 'cd /path/to/dir' and gnome-terminal -e 'cd /path/to/dir' but both give me errors when the new terminal opens. How do I get a new terminal to start in a specific ...
11
votes
4answers
4k views

How do I save terminal output to a file?

How do I save the output of a command to a file? Is there a way without using any software? I would like to know how.
11
votes
5answers
8k views

trim the terminal command prompt working directory

When using the terminal in a deep folder structure sometimes the prompt can take up most of the line. Is there any way in which I can trim the working directory? I know I can do PS1="\W >" to only ...
5
votes
1answer
24k views

Connecting to wireless networks from command line

I need to write a shell script which connects to one of the two available wi-fi connections. One is a un secure connection and the other is secure connection. My question has 2 parts- How to connect ...
14
votes
3answers
383 views

How can I know what programs does some apt-get package contains?

I would like to know what does some specific package install, for example, when installing ncurses, I have found that TAB key expands: sudo apt-get install ncurses- to show: ncurses-base ...
11
votes
2answers
5k views

How can I invoke a user switch from the command line?

In 11.10 I used 'gdmflexiserver -xnest' to switch users without logging out however I think gdm has now been completely removed. I'm trying to bind a keyboard shortcut to do the equivalent of 'Me ...
11
votes
2answers
16k views

Environment variables when run with 'sudo'

As example to my question, my ~/.bashrc file contains this lines: > export LD_LIBRARY_PATH=/opt/intel/mkl/lib/ia32:$LD_LIBRARY_PATH > export LD_PRELOAD=/opt/intel/mkl/lib/ia32/libmkl_core.so ...
9
votes
5answers
8k views

Search for duplicate file names within folder hierarchy?

I have a folder called img, this folder has many levels of sub-folders, all of which containing images. I am going to import them into an image server. Normally images (or any files) can have the ...
11
votes
1answer
5k views

What commands are needed to install Ubuntu Core?

Ubuntu Core's wiki page page contains the instructions to install Ubuntu Core on a target media: Uncompress (do not unpack) rootfs Format target media: at least one partition should be ext2, ...
11
votes
4answers
13k views

How do you change brightness, color and sharpness from command line?

I am controlling my PC with SSH and scripting. How can i change the brightness, color and sharpness from command line? Try 1: failed $ sudo redshift -t 5000:5000 -g .5 Cannot list GNOME panel ...
11
votes
3answers
3k views

How to set the Default Browser from the Command Line?

Tried to set the default browser using the GUI tools but this didn't work overall. Is there a way to configure the system wide default browser from command line?
9
votes
2answers
12k views

How do I log all input and output in a terminal session?

How do I keep logs of all the work done via terminal? For example, I want a record of all the work done on database via terminal.
9
votes
5answers
19k views

How to make Terminal semi-transparent?

I am running Ubuntu 11.04 with gnome 2.3 and I would like my terminal window to be transparent. The problems is the transparent settings in my terminal just shows the desktop background and not the ...
7
votes
1answer
1k views

How to make a directory with permanent permissions different from default

I have system-wide default permissions set with umask 027. I am in the need to make a directory whose sub-directories would need 775 permission and whose files would need 664 permissions and make ...
7
votes
3answers
3k views

Can I configure a transparent terminal over my wallpaper?

Can I make a transparent terminal wallpaper on my desktop? I've done this in the past but can't remember what I did.
27
votes
3answers
11k views

Difference between 'dir' and 'ls' terminal commands?

I've been trying to find the difference between using the dir and ls commands in terminal. I know ls is the traditional unix method of viewing the files in a directory, and that dir is the windows ...
23
votes
6answers
14k views

How do I change directory to a folder with special characters?

I am using Ubuntu 11.10 and in terminal I want to enter the following folder: cd Milano, Torino (Jan)-Compressed And it does not work! How should I write the command cd to enter this directory?
14
votes
3answers
31k views

What is the difference between 'su -' , 'sudo bash' and 'sudo sh'?

I would like to know what is the difference between su - sudo bash sudo sh I cannot login as root while doing su - because I do not have the root password - I mean I have my user password with ...
12
votes
2answers
25k views

How do I switch from LightDM to GDM?

How do I switch from the default display manager (Lightdm) to the older display manager (GDM)?
7
votes
5answers
37k views

Can't execute .out files, getting permission denied

I have written a C++ program and complied it to produce a.out file. However, whenever I try to run it, I get Permission Denied. I read that we can use sudo, but I can't quite get it to work. I use ...
6
votes
3answers
9k views

Warnings while launching gedit from the Ubuntu terminal

I am facing these warnings while launching gedit from my terminal. Eventually gedit starts, but with these lines of warning every time when I launch gedit: (gedit:3830): Gtk-WARNING **: Theme parsing ...
7
votes
3answers
8k views

Executing .bat file

I have a setup.bat file which install some applications and i want to execute it. This is content of .bat file : @echo off cls Rip_7z.exe x Rip0.7z cls del Rip0.7z cls Rip_7z.exe x Rip1.7z cls del ...
4
votes
3answers
13k views

How can I add a desktop/GUI to a command-line Ubuntu installation?

I had installed Ubuntu on a VM, with a command-line only interface, now I have had enough of command-line interface experience and plan to proceed with GUI mode. But I dont want to install a fresh ...
2
votes
1answer
563 views

Adding a Wine (.exe) file to open/play files in Thunar's 'Custom Actions'

What is the line parameter in Thunar's "custom actions" that would play a music directory in a Wine (.exe) program? I want to put Foobar2000 (and possibly other such applications) in Thunar's Custom ...
2
votes
1answer
5k views

Run simple bash script to start applications at login

I want to run a simple bash script automatically when I log in. For example #!/bin/bash echo "start spotify" gnome-terminal -e spotify --title spotify When I run this command, one gnome-terminal ...
12
votes
2answers
269 views

What does “$$” mean in the shell?

What does the output of the command below mean? (result is positive integer) echo $$