Need to find vi command to remove ^H from command man find > find.txt

Need to find vi command to remove ^H from command man find > find.txt

Post by Iskandar » Sun, 04 Apr 1999 04:00:00



hi there,

Q1: i need to find out the vi command needed to change all occurences of
some character followed by a backspace to nothing.  that is to remove the ^H
sequence created by the following command man find > find.txt .
Q2:can sed perform the same task as vi?

Q3:what would be the command also for sed ?

thanks.

Iskandar

 
 
 

Need to find vi command to remove ^H from command man find > find.txt

Post by Michael Wa » Sun, 04 Apr 1999 04:00:00



>hi there,

>Q1: i need to find out the vi command needed to change all occurences of
>some character followed by a backspace to nothing.  that is to remove the ^H
>sequence created by the following command man find > find.txt .
>Q2:can sed perform the same task as vi?
>Q3:what would be the command also for sed ?

All you asked above is all possible. But if you state what you want to
do, rather the means that you want to use, the answer would be a lot
simple: man find | col -b > find.text
--
Michael Wang
http://www.mindspring.com/~mwang

 
 
 

Need to find vi command to remove ^H from command man find > find.txt

Post by Ken Pizzi » Sun, 04 Apr 1999 04:00:00



>Q1: i need to find out the vi command needed to change all occurences of
>some character followed by a backspace to nothing.  that is to remove the ^H
>sequence created by the following command man find > find.txt .

:%s/.^H//g

Quote:>Q2:can sed perform the same task as vi?

Yes

Quote:>Q3:what would be the command also for sed ?

sed 's/.^H//g'

In both cases above the ^H should be replaced by a literal
Control-H character.  This must (in vi) or might (depending
on your shell and your stty settings) be accomplished by
typing Control-V Control-H.

As someone else pointed out, "col" might be a more suitable
solution to your problem, however.

                --Ken Pizzini

 
 
 

Need to find vi command to remove ^H from command man find > find.txt

Post by Michel Tuga » Tue, 06 Apr 1999 04:00:00



> Q1: i need to find out the vi command needed to change all occurences of
> some character followed by a backspace to nothing.  that is to remove the ^H
> sequence created by the following command man find > find.txt .
> Q2:can sed perform the same task as vi?
> Q3:what would be the command also for sed ?

#
# man like BSD:
#       stop at each page (more)
#       go to vi from more (readable text)
#
alias sman=_sman
function _sman {
        man $* | sed -e 's/.^H//g' | uniq > /tmp/sman$$
        more /tmp/sman$$
        /bin/rm -f /tmp/sman$$

Quote:}

--
                                Michel Tugaye

 
 
 

Need to find vi command to remove ^H from command man find > find.txt

Post by lenlut » Fri, 09 Apr 1999 04:00:00


or is it
:g/^V^H/s////g



> > Q1: i need to find out the vi command needed to change all occurences of
> > some character followed by a backspace to nothing.  that is to remove the ^H
> > sequence created by the following command man find > find.txt .

> > Q2:can sed perform the same task as vi?
> > Q3:what would be the command also for sed ?

> #
> # man like BSD:
> #       stop at each page (more)
> #       go to vi from more (readable text)
> #
> alias sman=_sman
> function _sman {
>         man $* | sed -e 's/.^H//g' | uniq > /tmp/sman$$
>         more /tmp/sman$$
>         /bin/rm -f /tmp/sman$$
> }

> --
>                                 Michel Tugaye


--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Most of what I have learned has been taught to me by others.
I guess that means I have to teach others what I have learned
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Lately It Occurs To Me
What A Long Strange Trip Its Been
(R. Hunter)
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 
 
 

Need to find vi command to remove ^H from command man find > find.txt

Post by Kosh Banerj » Sat, 10 Apr 1999 04:00:00


I suspect that the original poster was referring to man pages when wanting to
remove ^H. The simplest solution is:

man (something) | col -b > something.txt

I am not 100% sure that the proper option to use with the "col" command is
"-b". Please consult the man page.


> or is it
> :g/^V^H/s////g



> > > Q1: i need to find out the vi command needed to change all occurences of
> > > some character followed by a backspace to nothing.  that is to remove the
>  ^H
> > > sequence created by the following command man find > find.txt .

> > > Q2:can sed perform the same task as vi?
> > > Q3:what would be the command also for sed ?

> > #
> > # man like BSD:
> > #       stop at each page (more)
> > #       go to vi from more (readable text)
> > #
> > alias sman=_sman
> > function _sman {
> >         man $* | sed -e 's/.^H//g' | uniq > /tmp/sman$$
> >         more /tmp/sman$$
> >         /bin/rm -f /tmp/sman$$
> > }

> > --
> >                                 Michel Tugaye


 
 
 

1. Need to find info on the 'FIND' command

I started taking an Operating System class at school and our first
assignment is to find specific files on a file system, I just got a copy
of Linux and found that it had a find command that enables you to find
files. I would like to know where and how can I uptain the code for this
file?

I tried using the 'find' command to find the code for the program but it
only found the readme file that goes with it. any help would be greatly
appricated.

2. Building X windows stuff

3. need to pipe a find or locate command into the rm command....PLEASE help!

4. Need help tracing regular write activity in 5 s interval

5. Patch for 1.3.43?

6. >>>Compiling 2.0 problem: "asm86: Command not found" <<<

7. 2.5.20 swsusp: stop abusing headers with non-inlined functions

8. find command to find files of a certain date

9. "find" command to find file on specific date?

10. ?updatedb: @find@: command not found???