Solved

!

Posted on 1998-02-19
4
192 Views
Last Modified: 2011-09-20
UNIXer,

What is the usage of "!" ??????

Andrew
0
Comment
Question by:andrewyu
4 Comments
 
LVL 84

Expert Comment

by:ozo
ID: 2008822
In what context?
0
 

Accepted Solution

by:
rams021898 earned 0 total points
ID: 2008823
a) In the sed utility, the "!" is used to match all lines not cvoered in the address.

b) In the awk utility, the "!" is the negation operator.

c) When you type "history", you will get your history list of commands.  Typing "!" and a number will execute that specific command.

or even

d)In ftp, the "!" command tells ftp that you want to run a shell comman on your local host (like "!ls").

I think that's most, if not all of its uses.

Hope this helped....
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 2008824
In a couple of apps (rams still mentioned ftp) it is the shell escape (ex, ed, vi, etc.).
rams, in c) you asume csh, tcsh or something similar ;-)

0
 
LVL 3

Expert Comment

by:braveheart
ID: 2008825
! is also often a history operator in debuggers and similar applications. In the csh, it is also a negation operator. I'll bet that we haven't exhausted all the possibilities yet.
0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

When you do backups in the Solaris Operating System, the file system must be inactive. Otherwise, the output may be inconsistent. A file system is inactive when it's unmounted or it's write-locked by the operating system. Although the fssnap utility…
Introduction Regular patching is part of a system administrator's tasks. However, many patches require that the system be in single-user mode before they can be installed. A cluster patch in particular can take quite a while to apply if the machine…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now