General :: Unix - 'man' Command: Search For A Word/phrase And Cycle Through?
Jun 29, 2011
When looking for a certain word or phrase in the man page of linux command, one can type '/' followed by the word/phrase to search for it. What I'd like to be able to do is to search for the next occurrence of the word/phrase without having to type it out again. Kinda like when you use 'ctrl+f' in a browser to search for a word, and then press 'enter' to find the next occurrence of that word.If this is possible to do, how do I do it?
Want to search for ~ and delete it as well as to append the entire line to the above line. For Ex:
1111xxxx date Sandy area is ~around this area.3222xxx date There seems to ~left side of map, the colours are accurate (showing green areas)Even if I ~zoom in, the green parks, xxx3258 date The dammed up ~away, the "other" body of water varies ~blackNatural gas leaching.
IT MUST LOOK LIKE:
1111xxxx date Sandy area is around this area. 3222xxx date There seems to left side of map, the colours are accurate (showing green areas)Even if I zoom in, the green parks, xxx3258 date The dammed up away, the "other" body of water varies blackNatural gas leaching.
i am using openSUSE 10.3 & like to use power of terminal to do tasks.I want to search all files containing word 'echo' in given folder.What should be command.
I am using ascript for general users to back up usb drives to lto4 tapes.. I wish to ahve some error checking to check IF is there is a tape in the tape drive to check for the tape:
if i do a sudo mt -f /dev/st0 status i will get back a mt: /dev/st0: rmtioctl failed: Input/output error if there is no tape in the drive or sudo mt -f /dev/st0 status
I want to know that how can i search for a word in a file and then comment it or delete it. I know this command works.
sed 's/word/#word/'g inputfile > outputfile
But the lines in my input file are as under:
zone "abc.com" { ---- This line can be comment type master; ----- This line repeat again and again in the file file "abc.txt"; allow-query { any; }; -This line repeat again and again in the file };
I tried to run % mvdir earlier and it said command not found. I then ran a search for it and still not found.Is there a place I can download the script for the command, and is there any information I should know post-download to get it to work?
This question may be silly and super easy for linux connaisseurs, but I was just wondering, for instance, I want to use the >find command to search for a file and send the results to a text file
I'm pretty sure this is super simple, but I've searched and searched and for the life of me I can't find any info on how to limit the columns that display in the interactive top program with arguments passed from the command line. I recall seeing something formatted like this ...
~/top -f (kdx)
Which would only show the %CPU, UID, program name fields/columns. I'd like to display the results in a really narrow terminal window on the right side of my desktop.
I hope to add a wrapper script for the command with different parameters. For example, for any Unix command or script, like below: command.sh -s p1 -o p2 -q p3 or command.sh
Probably we could do as this way cat wrapper $1 $2 $3 $4 $5 $6 $7 | tee test.log (assume it has 0 to 6 parameters)
and use it like wrapper command.sh -s p1 -o p2 -q p3 wrapper command.sh
It is a little ugly to list all fixed parameter as above, do we have better code to handle various parameters?
I am trying to ssh into my server from the command-line without including the username in the url. I do not want it to send any username, as it currently takes the active account and sends that as user.ex:
ssh server.com -> (doesn't send default username)
instead of [URL] I would want to input username directly into the server, just like it is done using putty on windows. he wants to be prompted for a username, rather than having to provide one when connecting - but I don't really see the utility in such a thing. - birryree Sep 8 at 17:41
In formsweb.cfg file are two lines with labels archive_jini= and archive= at the beginning of line. After equal sign (=) is row of filenames of java archives delimited by coma(,). When I insert a new jar file in java directory, I have to append the very same name of jar file to both lines if that name is not yet present.
Every time I need to find a file and then open it, I have to use : find ./ -name **.properties. , then copy the result, and then vi "paste the result here" . If I need to use a mouse, it can be a little trouble. So is there any better way to do this?
This is a bit of a long shot and I think the answer will be no but I thought I'd ask just in case. I have a number of tutorials in html but I want to be able to search for particular information in these files and display that information in the terminal rather than having to go through a browser. Apart from using grep which gives a pretty messy display or having to write a a specially Bash or python script, is there any command line tools that can provide such a function?
I sometimes get confused by the varying command line options I need to run common Unix archiving and compression software (e.g. gzip, bzip2, zip, tar).
Is there a program out there that can just Do What I Mean for common cases? For example:
I want to search file excluding the NFS ...find / -mount -name 'filename' restricts the search only in the root disc partition,but the file can be in other partitions alsoIs there any way to exclude the NFS only.
Trying to find a way to have the find command perform a search using multiple file extensions such as "find all pics" i.e. .jpg, .png, .gif, .raw etc. I would have thought something like the following would have worked, but apparently I'm doing something wrong:
sudo find / -type f -iname "*.jpg" "*.png" "*.gif" -printf
I'm guessing find simply doesn't support more than one "-name/-iname" at a time? Or perhaps I'm going about this the wrong way? I realize most times there's several different ways to skin a cat when a task is requested in linux/unix.