A shell is software that lets users interact with the operating system, usually by typing at a command-line.

learn more… | top users | synonyms

5
votes
3answers
29k views

how can i install CentOS 6 without the gui?

i just downloaded the centos 6 live cd and i tried installing it on virtually and i am never prompted to install centos with/without gui and its all automated. what happends is after i am booted into ...
5
votes
5answers
1k views

What is the difference between “Shell” and “Terminal”?

I am fairly new to Ubuntu and I am loving it! But I don't quite understand the difference between the shell and the terminal. Can any one explain? Someone told me that a terminal is just a "tool" to ...
4
votes
4answers
2k views

Does “chmod 777 .* -R” chmod parent directories (..)?

Does "chmod 777 .* -R" chmod parent directories (..) recursively?
3
votes
3answers
3k views

How to store a Unix alias?

I know I can create an alias for untar like this alias untar=’tar -xvzf’ How do I make this persist from session to session, because it seems it is lost when I reconnect?
2
votes
0answers
83 views

Downloading and building O3D

I'm trying to get a program called O3D into my computer by following the instructions on O3D's wiki. I tried to download the project to my directory but the prompt gave me this answer: gclient is ...
2
votes
2answers
555 views

Tool for diffing large files

When I use "diff" to find the difference between two large data files, diff A.txt B.txt > dif.info it is output: diff:memory exhausted or add the argument "-H" diff -H A.txt B.txt > ...
2
votes
2answers
7k views

Is it possible to use putty as the UI for the Windows shell?

PuTTY is much better than cmd.exe. Can I use PuTTY to execute Windows commands?
2
votes
2answers
4k views

Terminal emulator with split panes for Mac OSX

I'm looking for a terminal emulator on Mac OSX with a specific feature: to be able to split the console window into multiple panes. It's a great feature of Terminator for gnome, I think this image ...
2
votes
2answers
240 views

History of commands?

Is there any way to find which commands have been executed between 2 specific dates (like 2 to 3 months period)? I can use the history command, but I have powered the system on/off. Is this ...
1
vote
2answers
322 views

run any shell script from Fish and import all exported env variables?

Is it possible somehow to import all environment variables which are exported by a subprocess started by Fish? E.g. from my Fish session, I start bash ~/.profile, which exports some variables and I ...
1
vote
2answers
1k views

Diff and ignore lines missing in one file

I want to diff two files and ignore lines that are present in one file but missing in the other. For example File1: foo bar baz bat File2: foo ball bat I'm currently running the following diff ...
1
vote
2answers
4k views

How to access a shared drive from the command prompt on OS X

I have a shared drive called "music". It shows up in Finder without problems. How do I access this from the command prompt on a Mac? I can't find it anywhere – is there a way to access it?
1
vote
3answers
1k views

Alias to open gVim (Cream version) from Cygwin shell

I'm using the Cream version of gVim, and i'd like to make an alias to open files from a Cygwin shell in Cream. Running the gVim executable from Cygwin gives the following error (in a Windows cmd ...
1
vote
3answers
26k views

Need some help with Terminal Emulator (Android app) commands. (Similar to Linux commands)

I'm trying to follow this tutorial to install Mobile Defense as a system application on my Motorola Droid. I want to use Terminal Emulator and the commands are basically the same. The only two ...
0
votes
2answers
67 views

sum numbers in different lines in shell

i have 8000 lines similar to this <Flow flowId="1" timeFirstTxPacket="+0.0ns" timeFirstRxPacket="+924100.0ns" timeLastTxPacket="+199984927558.0ns" timeLastRxPacket="+199675473275.0ns" ...
0
votes
1answer
58 views

combining bourne shell and awk

This is my actual file WASfile #!/bin/sh sed -i '/^ *$/d' WASfile sed -i -e '/user=/,/group_1=/{w /tmp/1' -e 'd}' /home/wasdm/WASfile; Script to Add read -p "Press [Enter] to continue for ...
0
votes
2answers
256 views

Removing duplicate files, keeping only the newest file

I'm trying to clean up a photo dump folder, in which several files are duplicated but with different filenames or lost in subfolders. I've looked at tools like rmlint, duff and fdupes, but I can't ...
0
votes
1answer
528 views

“noshell” for ssh proxy users

I like to setup a special ssh user which is only allowed to tunnel web traffice through my server. I do not want to make an open proxy. This brings me to my question: Is there a "noshell" shell for ...
11
votes
2answers
10k views

Unix: How to merge two directories

Say I have two folders with various content, foo and bar. How can I merge bar into foo so that: Files in foo that are not in bar are untouched. Files in bar that are not in foo are now in foo. Files ...
8
votes
2answers
707 views

Making bash TAB completion more like cmd.exe [duplicate]

I wondered if theres a way to do rotational style completion in bash similar to the behavoir on cmd.exe, I've found it speeds me up in regard to entering commands
7
votes
3answers
7k views

Run a GUI app on remote computer from SSH

I want to run a GUI application on my Ubuntu computer, but it should started by a shell script on my Debian server trought SSH. Is this possible?
6
votes
2answers
1k views

Writing shell scripts that will run on any shell (using multiple shebang lines?)

I've just started getting deeper into shell scripting, and I've always just thrown my script in a file, marked it chmod +x and then done /path/to/script.sh and let whatever interpreter is the default ...
6
votes
2answers
1k views

re-use '~/.profile` for Fish?

(I'm talking about the shell Fish, esp. Fish's Fish.) For Bash/ZSH, I had ~/.profile with some exports, aliases and other stuff. I don't want to have a separate config for environment variables for ...
5
votes
4answers
1k views

BASH history truncated to 500 lines on each login

For some reason, I cannot get my system to keep my BASH history after a reboot. Here are the relevant sections of my ~/.bashrc: shopt -s histappend PROMPT_COMMAND='history -a; updateWindowTitle' ...
5
votes
2answers
158 views

Differences in bash scripts between $@ and $*

Which are the differences between $@ and $* ? For example I see no differences here: #! /bin/bash echo with star: $* echo with at sign: $@
4
votes
4answers
5k views

rsync using regex to include only some files

I am trying to run rsync to copy some files recursively down a path based on their file name pattern, case insensitive. This is what I have done to run rsync: $ rsync -avvz --include ='*/' ...
4
votes
3answers
4k views

What is the difference between Linux (Ubuntu) and Mac shell commands?

I use Ubuntu at work and a Mac at home. I was trying out some shell commands on my bash terminal on the Mac today but they didn't work. I was told both machines should operate UNIX commands so the ...
4
votes
3answers
5k views

What is the default terminal (shell) for Xubuntu?

What is the default terminal (shell) for Xubuntu? Does Xubuntu use the same shell as Ubuntu?
4
votes
1answer
320 views

how to copy I/O not just redirect (Windows and Linux)

I have a simple call command call calabash -D sim.xpl >test.txt 2>&1 and this redirects into test.txt, how do I do both redirect into a file and allow it to show up in the prompt? (I ...
4
votes
4answers
2k views

How do I “globalize” binaries in Linux?

For example, any binary placed in /usr/local/bin will run in any location. If I were to place binaries inside /myname/local/bin how would I be able to accomplish the same thing?
4
votes
6answers
6k views

Why does my LD_LIBRARY_PATH get unset launching terminal?

I have a shell script to set up some environment variables and launch whatever program I send in as an argument: export PATH=$HOME/local/bin:$PATH export ...
3
votes
1answer
426 views

Parse multiple HTML to text and rename as parent Directory

In a directory there are many folders .html inside, I would like all HTML parsed as new .txt with the name of the parent directory. Example1/ Index.html>Example1.txt Example2/ ...
3
votes
1answer
889 views

How to delete readonly variable in bash?

$ mySite="superuser" $ readonly mySite $ unset mySite bash: unset: mySite: cannot unset: readonly variable How can we delete mySite, as it is a readonly variable?
3
votes
1answer
591 views

How can I run an AppleScript or shell command on Mac OS X at screen unlock?

Note that this is not the same as startup or login. I never log out of my machine and I want to run the script whenever I unlock the machine to start working.
3
votes
3answers
784 views

Which shell to use to modify/replace Windows Explorer (don’t want fancy desktop but better browsing of folders/files… similar to Classic Shell)

I do know about the existence of alternative shells such as SharpE, Emerge Desktop, Ashton Shell, BB4Win, etc... I've looked into a few of those popular/famous ones, but they all seem to be very ...
3
votes
2answers
104 views

Is there a specific name for the .. or . on *nix systems?

Just what it says. Do they have a name besides "those dot thingies"?
2
votes
4answers
554 views

Bash script, string not replaced correctly with escaped $ and & characters

I have created a shell script which takes a string as input. If the string contains $ or &, then I need to replace those characters with \$ and \&. I could done that with sed command. After ...
2
votes
1answer
193 views

How to save shell history from emacs and use it in terminal?

I use emacs for almost everything, but when I run shell M-x shell and then exit from emacs, the history is not saved, I've tried (savehist-mode 1) for this purpose but it doesn't seem to work, is ...
2
votes
3answers
317 views

Mail me when someone runs sudo

I have added the below lines to /etc/sudoers.d/my_sudoers Defaults mail_always Defaults mailto="email@domain.com" I get an email every time sudo is run How can i modify this so I only ...
2
votes
3answers
2k views

Can I use pipe output as a shell script argument?

Suppose I have a bash shell script called Myscript.sh that need on argument as input. But I want the content of the text file called text.txt to be that argument. I have tried this but it does not ...
2
votes
2answers
1k views

execute command after process terminates in different shell

I am running a command that's processing some data in one shell window (let's say it has pid 200). Unfortunately I forgot to add the & to run it in the background. I need to run some analysis ...
2
votes
1answer
254 views

Distinguishing local and remote access in shell (TERM-related)

My default TERM is xterm-color. I would like it to be xterm-256color when I am working on my machine locally, but if I ssh to it I want to have it be xterm-color. How do I distinguish these two cases? ...
2
votes
1answer
305 views

iTunes OS X full system crash cont'd: is a bad media file the culprit? How do I isolate it?

THE ANSWER — NO SOLUTION It seems that this is a (hardware?) bug with the Intel iMacs and Mac Minis, as I discovered in this thread on Apple Support (which admittedly wasn't easy to find with that ...
2
votes
2answers
7k views

Using backslash to escape characters in cmd.exe

I see that the caret is the documented escape character. But, I have an example showing that for the double quote character, ^ doesn't work and you have to use \ C:\>runas /user:Administrator ...
2
votes
2answers
3k views

Is it possible to access the shell (Darwin) on an iPhone?

In order to write some little script for example.
1
vote
4answers
76 views

Catalog of programs listed in bash

In bash (or any other shell), when you type "firefox" or another command, how does bash point it to its actual location (/usr/bin/firefox)? Also, where is the "catalog" for bash autocomplete?
1
vote
1answer
422 views

How can I list directories first in the terminal with zsh / ls command in Mac OSX?

Most of the similar questions / answers here don't work in Mac/OSX because there is not such a thing as --options. I am using the ZSH shell, I've been trying commands said here: ...
1
vote
3answers
258 views

Colored PS1 string

Clarification: I want __foo to be executed each time the PS1 string is presented in the terminal, not when the PS1 string is constructed (hence its being in quotes). __foo contains logic that examines ...
1
vote
2answers
697 views

Running a webserver behind a firewall I have no access to

I'm having a bad time in my student appartment: I want to run a webserver on my Laptop, which should be reachable from outside of the net. I'm sitting behind some proxy-server that passes outgoing ...
1
vote
0answers
45 views

what are commands for tc shaping,queueing and scheduling?

I have 3 virtual machines and i fixed them as a team and in 1 local host now they can ping each other and see each other now how can I write a command to see shaping using traffic controller (tc)? is ...