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

learn more… | top users | synonyms

0
votes
2answers
218 views

Ignore variables from another shell

I am on a linux workstation in a network, with an "old" distrib. Furthermore, login shell is enforced to CSH. I already asked to Admins if it would be possible to switch to another one (I would like ...
10
votes
1answer
2k views

ZSH tab completion of git commands is very slow. How can I turn it off?

If I type: rm <TAB> I'll see possible completions almost instantly. However, if I type: git rm <TAB> It'll hang for several seconds if it's in a git repo, or fail to show any ...
0
votes
1answer
158 views

Shell access without forwarding ports

This may be a stupid question but can you obtain shell access to a web server by means of not forwarding any ports? I am at work and can't forward any ports to allow access. Are there alternatives? ...
3
votes
2answers
440 views

SQLITE3 for dummies - solved (sort of)

I'm trying to learn the SQLite with "sqlite3 -interactive" shell (under Cygwin). For supposedly all legal reasons the sqlite3 shows the following prompt every time I forget to add a semicolon at the ...
3
votes
1answer
801 views

Order of execution and purpose of .profile vs .zshrc

Few questions: What is a distinct purpose of .profile and .zshrc? What gets called first when the shell comes to life?
-2
votes
3answers
155 views

How can I get a list of commands used for navigating in the terminal?

In the terminal, what should I type to show a list consisting of command items such as these: ls: show direcrtory cd: move to directory … and so on. What command can you use to display this list? ...
2
votes
2answers
130 views

Can I use an ssh client or something similar to run commands on the local machine from a remote machine?

I have a machine which I cannot ssh into. I would like to be able to have controll a shell session in it. Is there some way to have it connect out to another machine and for me to issue commands on ...
3
votes
1answer
91 views

how to make getopts just read the first character post `-` [closed]

I have a shell script testShell.sh which uses getopts as below: #!/bin/bash while getopts ":j:e:" option; do case "$option" in j) MYHOSTNAME=$OPTARG ;; e) SCRIPT_PATH=$OPTARG ;; ...
1
vote
1answer
957 views

Does Linux save the history of executed commands

I know we can do a "history" command or use control+R to find the command history in a particular shell session. But is there a way to find out the command history of my last ssh session for example? ...
1
vote
2answers
701 views

is there an 'upwards' find?

I found I asked this question on the wrong stackexchange site. To find files starting from a certain path, I can use find <path> .... If I want to find 'upwards', i.e. in the parent directory, ...
4
votes
2answers
505 views

What's DING!? Shell prompt with time in it

I am using tcsh shell. I put time in my shell prompt. It shows me DING! sometimes, what's up with that? /home/snihalani on master at 2:55pm => /home/snihalani on master at DING! => ...
1
vote
2answers
311 views

Combined sudo su deploy command doesn't work, does when separate

I have this command: ubuntu@ip-10:~$ sudo su deploy -c 'rvm install 1.9.3' bash: rvm: command not found I also tried: ubuntu@ip-10:~$ sudo su deploy -c 'source /home/deploy/.bashrc && rvm ...
10
votes
2answers
9k views

How can I found out if file is alias or symbolic link?

I'm working on a legacy system and I have a bunch of files that are referencing images that are located in other folders. lrwxrwxrwx 1 user nobody 56 Feb 10 2010 t100x100.jpg -> ...
0
votes
2answers
356 views

exclude files from list that begin by string in unix

I'm using s3cmd top copy files to S3 but I want to exclude all files that begin with 00 and are a JPEG. I'm trying --exclude=00*.jpg with no success. Any idea how to do this?
3
votes
1answer
577 views

How to specify for emacs tramp which remote shell to open?

Besides opening remote files, tramp can be used to run a remote shell. Unfortunately, there is a problem. On a local machine i have zsh and on remote server only bash is installed. Issuing M-x shell ...
0
votes
1answer
225 views

How do I configure gvim to open files from the current directory?

On Windows, no matter what I set as the current directory, gVim will always set its initial working directory to $home. (That is, if I launch gVim with the current directory at C:\something, or if I ...
0
votes
1answer
81 views

Segmentation fault when running bib2x

I'm working on an unfamiliar machine and I am trying to get a program called bib2x to work. Unfortunately, when I run the program, I keep getting a segmentation fault. My (limited) experience and ...
5
votes
2answers
2k views

How to copy files on unix shell using wildcards

I'm trying to copy some files into existing folders. This is an example of the schema # origin /home/user/myfiles/folder1/group1/1.jpg /home/user/myfiles/folder1/group1/2.jpg ...
3
votes
2answers
1k views

Command prompt takes 7-8 seconds to load in Windows 7

When I go to Run and type cmd, it takes about 7-8 seconds for the command prompt to appear. I have a Core i5 with 3GB of RAM running Windows 7 x86. I really need the command prompt to run instantly ...
5
votes
1answer
61 views

How can I suspend a whole command sequence in a shell?

How can I suspend a whole command sequence in bash or zsh (or maybe some other shell)? For example, if I run: sleep 100; echo foo and press Ctrl + Z, sleep is suspended and put into background, ...
0
votes
1answer
1k views

How to prevent Shell auto-logout from terminating my screen session?

c shell and echo $autologout shows 60 But I can not unset this variable since it`s read-only, error message: set: $autologout is read-only. Everytime when the shell is auto logged out, my screen ...
12
votes
4answers
1k views

bash: colorized man page

Where do I have to take a look at in the system to colorize the man pages? The man pages are viewed with less, so I tried adding the following lines to my .bashrc to change the colors: (Which works ...
7
votes
3answers
2k views

How to run Vim command from the shell?

This might be a dumb question, but bear with me. I'm automating some of the usual stuff I do when setting up a new work environment, and would like to automate the Vim command :BundleInstall (for ...
21
votes
3answers
16k views

What is the difference between CMD and Command prompt in windows?

Until now, I never thought (and never observed) that cmd and command are two different things. Well, are they? Take a look at this pic: Actually, I usually open cmd from the Run dialog whenever I ...
-2
votes
2answers
5k views

copying file from local machine to remote server using ssh

How do I copy a file from my local machine to a remote server using ssh, I have tried the following code: scp -o StrictHostKeyChecking=no -r $tarpath/$user@$server:$perfresdir/temp/ACK/
3
votes
3answers
5k views

Linux Ubuntu 12.04 high Load without high cpu/ram usage. Which tools and techniques to diagnose/solve this?

I'm having a huge load after install Linux Ubuntu 12.04 My machine now is a Intel G620/4G RAM/ 1T HD, before it was a Amd X2 5000/4G RAM/250G HD Now uptime in idle mode: 12:45:03 up 3 days, ...
4
votes
2answers
2k views

Does the Linux 'nice' command work on any shell script?

Does nice work on any shell script, or does it work on basic Linux commands only? For example, if I have a custom shell script that contains a sort function, and I call nice myscript.sh would ...
0
votes
1answer
356 views

Cygwin shell is overriding my Windows shell

I'm not sure what I did, but I've somehow got Cygwin installed in such a way that even when I try to run an ordinary windows shell, Cygwin is interfering. I have batch scripts that I want to run in ...
1
vote
1answer
789 views

Unix tool to output first n characters in an UTF-8 encoded file

I want to print the first 1000 characters in an UTF-8 encoded file. I know that the head tool can print the first n bytes of a file, but it may cut a character in the middle so that I get garbled ...
2
votes
3answers
705 views

How do I create a soft link to all executables in a different directory?

I am trying to create soft links to mingw's binaries in cygwin. So far I have: find /cygdrive/c/MinGW/bin/ -name "*.exe" -exec ln -s {} basename {} \; but I get: ln: target ...
8
votes
3answers
1k views

How can I keep the color when I run the external command inside vim?

For example, for the command ls --color displays colorful results when being executed in the shell. However, when I call :!ls --color inside vim, all color information is gone. What should I do to ...
2
votes
1answer
158 views

What's the owner of the file in OSX for a program, or how to get it?

I'm using Mac OS X 10.7. Today I created a new user account, and moved everything under my own user account to my new one, and did a command: sudo chown -R [new_user_name] /Applications sudo chown -R ...
-5
votes
1answer
172 views

is Windows Vista x64 Ultimate secure with replaced shell explorer.exe? [closed]

I've replaced explorer.exe as the default shell with steam.exe using a program called instant sheller. I don't want to run the stock firewall, and want to invoke the firewall and antivirus from the ...
3
votes
1answer
823 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.
27
votes
1answer
4k views

chain Fish commands via `&&` or `||`

In Bash/ZSH and other shells, I am used to using && and ||. Is there any equivalent in Fish?
1
vote
2answers
514 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 ...
9
votes
4answers
3k 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 ...
0
votes
1answer
87 views

Bash Profile Coloring

I would like to make a few changes to my bash profile. Changes I would like include: Coloring Files: I would like files with the execute permission bit set to be colored green. I would like to ...
2
votes
2answers
1k views

Shell Script, iterating over a folder

I have very basic shell scripting knowledge. I have photos under original folder on many different folder like this folder + folder1 + original + folder2 + original + folder3 + ...
2
votes
2answers
330 views

Working shell command doesn't alias

I can run, svn status |grep -v .jasper$ |cut -d ' ' -f8 |sed '/.*\..*/!d' |xargs ls -altr --color=auto just fine. But when I go to add this as an alias (alias svtr="...") I get an error saying... ...
3
votes
2answers
339 views

Making aptitude work properly through a proxy invoked with sudo

I use Debian 6. I'm sitting behind a proxy, so I configured Debian to use that proxy. Browsing and any HTTP and FTP activity through GUI works OK. I wanted to update my package repository so I typed ...
3
votes
2answers
202 views

deleting /bin entries in linux

I have installed CentOS. I want to remove bzip2, so I enter this command in the shell: yum remove bzip2 bzip2-libs Then nearly 500 packages were removed and I can't enter any command. For example: ...
0
votes
1answer
190 views

zsh : How to list directory content with tab?

I just switched from BASH to ZSH and thing are pretty good, but: when I start typing cd /usr/share/s and hit TAB, this is what I get: $ cd /usr/share/sane/ sane/ skype/ ...
0
votes
1answer
35 views

Creating a link to name changing directory

I have an Ubuntu 12.04 installed using wubi + Win7. I'm trying to create a link to "my documents" directory which located in my C drive: C:\Users\Myuser\My Documents\ Since the Ubuntu is installed ...
1
vote
2answers
2k views

How to check what slows down my terminal startup?

Is there a way to check what slows down my terminal startup? I'm using zsh with ohmyzsh on iTerm2. It takes about 10 second to open a new window :( This is my zshrc file: export ...
0
votes
1answer
518 views

unable to edit file /proc/self/make-it-fail

I am editing file /proc/self/make-it-fail from root user. This file is having write permission but update not possible, showing "E667: Fsync failed" error.
4
votes
2answers
17k views

How to print new line character with echo?

I dump a string with hexdump like this 2031 3334 2e30 0a32 2032 3331 302e 000a. It is clear that 0x0a is new line character, however, when I try to echo this string out, I always got 1 430.2 2 13.0 -- ...
0
votes
0answers
234 views

Nano (pico) editor window resize

I am still not sure what I have done but I was testing some button combinations when I was in nano editor and all of a sudden the contents of the window started not to adjust themselves when I resized ...
-1
votes
3answers
917 views

Limiting files with wget

I'm trying to download mailing list archives such as http://cryolist.org/archives/ In particular, I have a page and would like to download every file linked from that page which ends with ".txt.gz". ...
0
votes
2answers
466 views

Linux WGET -O command for non existing folders?

I can't wget while there is no path already to save. I mean, wget doens't work for the non-existing paths. For e.g: wget -O /path/to/image/new_image.jpg http://www.example.com/old_image.jpg If ...