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

learn more… | top users | synonyms (1)

9
votes
3answers
863 views

Lowercasing all directories under a directory

I want to lowercase every directories' name under a directory. With which commands can I do that?
7
votes
1answer
1k views

Suggestions for a command line IRC client that supports downloads?

It's been awhile since I've used IRC and the last time I did was on a windows system with mIRC. I'm interested in finding a command line client that supports downloads and some degree of automation ...
6
votes
2answers
2k views

Invoking pushd in a shell script

I have a simple script that I want to invoke 'pushed' followed by another command. But the 'pushd' command inside the script doesn't seem to stick past the script. What's a way to make this execute ...
14
votes
2answers
2k views

How can I count the number of different characters in a file?

I would need a program, that outputs the number of the different characters in a file. Example: > stats testfile ' ': 207 'e': 186 'n': 102 Exists any tool, that do this?
2
votes
1answer
267 views

Open a command line window in GNOME Desktop

In GNOME Desktop, when I type /usr/bin/firefox, the Firefox browser will open. How can I open a command line window in the same way?
18
votes
8answers
10k views

Which mp3 tagging tool for Linux?

Which app would you recommend for Linux to tag MP3s? Under Windows I used to use tag&rename and liked it a lot; it works well under Wine, but I want something that runs natively
9
votes
7answers
5k views

How do you bulk move files up one directory safely?

How can I move files up a directory where there might be hundreds or thousands of files in the directory, and you might not be sure about whether there are dupes in ... What method would you use? How ...
1
vote
1answer
278 views

Commandline e-mail client that syncs contacts with external server?

I am planning to setup a groupware server that's either Citadel or SOGo, which supports the GroupDAV, CardDAV, or SyncML protocols. Is there a commandline e-mail client that supports syncing contacts ...
2
votes
3answers
759 views

How do I use redirection with sudo [duplicate]

Possible Duplicate: Redirecting stdout to a file you don't have write permission on Yeah I could (and probably will) just escalate to root, but I'd like to know why this doesn't work? ...
6
votes
5answers
7k views

How to pass the output of one command as the command-line argument to another?

So I have a script that, when I give it two addresses, will search two HTML links: echo http://maps.google.be/maps?saddr\=$1\&daddr\=$2 | sed 's/ /%/g' I want to send this to wget and then save ...
5
votes
3answers
287 views

Searching a text file with a single line using regular expressions

as far as i know all unix text processing utilities are reading one line at a time and performing one action on this line. I have a huge file with a single line of text which contains several tokens ...
46
votes
9answers
16k views

how do you sort du output by size?

How do you sort du -sh /dir/* by size? I read one site that said use | sort -n but that's obviously not right. Here's an example that is wrong. [~]# du -sh /var/* | sort -n 0 /var/mail 1.2M ...
9
votes
1answer
2k views

Searching for a command line tagging tool for mp3 and ogg that supports pictures

I am searching a command-line tagging tool that supports ogg- and mp3-tagging and allows to add a picture to the tags. Currently I use lltag but that does not support pictures. dagger is the tool I ...
5
votes
3answers
5k views

Storing output of command in shell variable

I have an operation using cut that I would like to assign result to a variable var4=echo ztemp.xml |cut -f1 -d '.' I get the error: ztemp.xml is not a command The value of var4 never gets ...
4
votes
4answers
1k views

Copy text from one terminal into another

I am logged into ssh to a university account from my home computer. Then I find a file that I want to copy onto my local system. So I open a new shell terminal and am about to use scp to copy that ...
6
votes
4answers
9k views

count lines in a file

I'm sure there are many ways to do this: how can I count the number of lines in a text file? $ <cmd> file.txt 1020 lines
9
votes
5answers
3k views

How to shut down the computer after a task has been completed?

I usually start a download before I go to school. Which command should I use to automatically make the necessary saves and turn off the computer after a particular task has been completed? (Say, ...
23
votes
4answers
13k views

Why do we use “./” to execute a file?

Why do we use ./filename to execute a file in linux? Why not just enter it like other commands gcc, ls etc...
14
votes
5answers
5k views

What is the difference between ls and l?

I accidentally typed l instead of ls today and found that the command still printed a list of the files in my current directory. Trying l --help brings up the help file for ls suggesting that l is ...
2
votes
6answers
2k views

truncating file names

I have a folder that has a number of files all of a similar form as: Dropkick Murphys - 01 - Walk Away.mp3 Dropkick Murphys - 02 - Workers Song.mp3 And so forth... I want to convert them all so ...
9
votes
2answers
695 views

Change directory without typing cd?

Is it possible to make bash change directory in command line simply by typing that directory without any commands like cd? For example is it possible instead of writing this: $ cd /tmp I just want ...
5
votes
2answers
1k views

sort output by column

I'd like to take this command find -maxdepth 1 -type d | while read -r dir; do printf "%s:\t" "$dir"; find "$dir" | wc -l; done ( from here ). which has an output of basically ./kennel: 11062 ...
28
votes
8answers
15k views

Markdown Viewer

I found a file formatted with Markdown. Could you guys suggest what viewer that I could use to view this type of files? Hopefully one without gui (if it's possible) Update I was actually looking for ...
2
votes
4answers
258 views

How can I manipulate the content of a file, by duplicating and changing some parts?

I want to manipulate a text-file. It contains many blocks of the form CLASS ...some stuff ... END I want to duplicate each of these blocks and add and remove a line of it's content. Can I script ...
16
votes
6answers
2k views

put history command onto command line without executing it

I use !n where (n) is the line number for executing a line in the history file I want executed at the command prompt which I find via history|less. But there is a command line history event I wish ...
69
votes
6answers
37k views

How can I close a terminal without killing the command running in it?

Sometimes I want to start a process and forget about it. If I start it from the command line, like this: redshift I can't close the terminal, or it will kill the process. Can I run a command in ...
11
votes
5answers
1k views

Is there a good combination of command-line and graphical file browser?

Is there a feasible solution than combines the advantages of a command-line and a graphical file browser? For example, the command-line is good to change the directory and execute commands but can't ...
6
votes
2answers
3k views

How can I install ncdu on Red Hat?

The answers provided to this question doesn't help. I'ved tried yum install ncdu But I'm getting No package ncdu available
7
votes
4answers
4k views

How to install software on Red Hat?

What's the simplest way to download/install software on Red Hat Linux (from bash command line)?
21
votes
7answers
6k views

How to understand what's taking up space?

I'm looking for a linux alternative to WinDirStat. I would like to know what is taking up space on my hard drives. A program that works on console and doesn't require a UI is preferred .
4
votes
1answer
526 views

Quick way to host a webserver on localhost

I'd like to make the contents of a folder available at http://localhost:PORT/, temporarily. A very basic http server. I already know about, $ python -m SimpleHttpServer or ( this seems like the ...
22
votes
4answers
4k views

How do I send stdin to the clipboard?

Is there functionality in unix that allows for the following: echo "Some Text" | copy-to-clipboard
2
votes
1answer
154 views

How do I view files as a tree structure?

I would like to view files exactly like I can view proccess using pstree. So is there something like: treeview --maxdepth 2 that would give me what I need?
1
vote
1answer
486 views

CH3MNAS Fun Plug and NZBget. Cannot launch NzbGet 0.7, word unexpected

I have un-tarred the nzbget0.70 debug version and have put it in the /ffp/bin dir. and I have a config file in the /ffp/etc/ dir but when I try to run it, I get the following: ...
10
votes
4answers
11k views

How can I make a program executable from everywhere

What should I do if I want to be able to run a given program regardless of my current directory? Should I create a symbolic link to the program in the /bin folder?
4
votes
1answer
108 views

What is this construct in bash? mycommand(){dosomething;}

I actually found following one-liner on commandfu.com: cmdfu(){ curl "http://www.commandlinefu.com/commands/matching/$@/$(echo -n $@ | openssl base64)/plaintext"; } I have not come across a similar ...
16
votes
4answers
19k views

Understanding the exclamation mark (!) in bash

I used history | less to get the lines of previous commands and from the numbers on the left hand side I found the line I wanted repeated (eg. 22) and did !22 at the command prompt and it ...
3
votes
2answers
391 views

I need help with a cronjob to watch for runaway processes and kill them

I have an interesting situation, I have a runaway ruby process - I know exactly how I trigger it. Point is, it got me thinking about runaway processes (CPU usage or memory usage). How would one ...
6
votes
3answers
751 views

Deleting lots of files

I accidentally created 8 million files and every time I'm trying to delete them the server almost dies because of the rm process eating all disk IO (the server is remote without console). Should ...
27
votes
3answers
30k views
3
votes
2answers
937 views

Difference between wget versions

I have problem with wget behavior for 1.10 and later versions. I am using wget to download a report from my app. version 1.10.2: >wget-1.10.2.exe --http-user=trader --http-passwd=trader ...
1
vote
1answer
109 views

How can I create a file that just contains a binary number?

I would like to create a file that just contains a binary number. I think that touch can be used to create an empty file, but is there any way I can fill it with a binary number e.g. 10 (ten)? And how ...
2
votes
1answer
942 views

How can I check the Base64 value for an integer?

I would like to check the Base64 value for an integer. There is a base64 linux command but I don't understand how I can apply it on integers. I have tried with base64 10 but then I get the error ...
5
votes
4answers
224 views

How could I simplify this command to only use awk?

awk '/user/ {print $1 }' /etc/userdomains | sed 's/://' the format of /etc/userdomains is domain.tld: user otherdomain.tld: otheruser
8
votes
2answers
811 views

How do I take a list and remove it from a file?

I have a long list of domain names that I need to remove from /etc/remotedomains. They're probably not in any particular order in the file. Each domain is on one line. How could I iterate through the ...
9
votes
3answers
10k views

Grabbing the first [x] characters for a string from a pipe

If I have really long output from a command (single line) but I know I only want the first [x] (let's say 8) characters of the output, what's the easiest way to get that? There aren't any delimiters.
3
votes
1answer
6k views

How to increase the TTY fontsize?

I have a fedora machine, I am used to working on CLI since I had CRT monitor, after switching to TFT - the experience is not the same I had with CRT, the font is smaller now. How to change it?
7
votes
6answers
6k views

Modifying PDF files

I need to do some basic editing on existing PDF file. I.e. I need to: Add chapters/bookmarks Change some page numbering However I cannot find any tool - GUI or commandline - which would offer this ...
1
vote
1answer
988 views

vnc connection working with PuTTY but not with command line

I am using PuTTY to connect to a distant network to then set up x11vnc and then using ssl/sshvnc as a client. in the host name for PuTTY I have: ssh.inf.uk and port: 22 in the ssh tunnel options I ...
3
votes
6answers
589 views

How do I find a command if I don't know its name?

As a Unix beginner, I often find myself wanting to know the name of the command that achieves a particular function I'm after. How can I go about finding out the name of the command, given a ...