Sponsored Content
Full Discussion: Swapping column in vi editor
Top Forums UNIX for Dummies Questions & Answers Swapping column in vi editor Post 302732671 by guruprasadpr on Monday 19th of November 2012 01:44:34 AM
Old 11-19-2012
Hi

Something like this:

Code:
:%s/\([^ ]*\) *\([^ ]*\)/\2 \1 /


Last edited by guruprasadpr; 11-19-2012 at 03:59 AM.. Reason: Removed g to prevent global substitution
 

10 More Discussions You Might Find Interesting

1. SuSE

Swapping

Hello! Why does my SuSE GNU/Linux machine swap? I have a Gig of ram, currently 14MBs of free RAM, 724MB - buffers and caches... That is 685MB of cached RAM, then kernel really should'nt have to swap, It should release cached memory in my thinkin... It has only swaped 3MB's but still,... (3 Replies)
Discussion started by: Esaia
3 Replies

2. UNIX for Dummies Questions & Answers

Pasting text in VI editor from a different editor

Hi, I knw its a silly question, but am a newbie to 'vi' editor. I'm forced to use this, hence kindly help me with this question. How can i paste a chunk 'copied from' a different editor(gedit) in 'vi editor'? As i see, p & P options does work only within 'vi'. (10 Replies)
Discussion started by: harishmitty
10 Replies

3. Shell Programming and Scripting

set EDITOR=vi -> default editor not setting for cron tab

Hi All, I am running a script , working very fine on cmd prompt. The problem is that when I open do crontab -e even after setting editor to vi by set EDITOR=vi it does not open a vi editor , rather it do as below..... ///////////////////////////////////////////////////// $ set... (6 Replies)
Discussion started by: aarora_98
6 Replies

4. Shell Programming and Scripting

VI editor,column postion

In VI editor ctrl + g is used indicate the line number on which the cursor is placed...similarly is there a way to determine the column number of the cursor position..? (1 Reply)
Discussion started by: vijay_0209
1 Replies

5. UNIX for Dummies Questions & Answers

Swapping in VI editor

Hi, I am attempting to replace several similar words with another word in vi. Here is what I have written for the script: 3dTcat -prefix SuperBrik_4WAY_HRF ../JULY10_2007A/results2TENT/stats.JULY10_2007A+tlrc ../JULY10_2007G/results2TENT/stats.JULY10_2007G+tlrc... (1 Reply)
Discussion started by: Jahn
1 Replies

6. Shell Programming and Scripting

Vi editor, copy one column?

This is an vi editor question. I do not know is this a right place to ask this question or not? I have a file with the following contents, 10 11 20 21 30 31 I want to copy first column that is 10,20,30 after second column, so that output will look like the following, 10 11 10 20 21 20... (3 Replies)
Discussion started by: MeetP
3 Replies

7. Solaris

How to set VI editor column size on Solaris?

I am setting the size using "stty columns 120" . But I still get the prompt saying "terminal too wide " when I am in vi. is there any time limit for this setting? how to set the column size to 120 permanently? Thanks in advance, Devi (4 Replies)
Discussion started by: pvkdevi
4 Replies

8. UNIX for Dummies Questions & Answers

Delete a specific column using vi editor?

Hello Experts, I'm a newbie so please excuse any wrong doings. I have a file that looks like this. abc def ghi jkl mno def abc ghi mno jkl ghi def mno jkl abc I would like the file to look like this abc def ghi jklmno def abc ghi mnojkl ghi def mno jklabc in other... (3 Replies)
Discussion started by: fnebiolo
3 Replies

9. UNIX for Dummies Questions & Answers

Removing 2nd Column in Vi Editor

I have text like this M83-306 132 797 M83-312 145 685 M83-315 321 479 M83-319 654 193 M83-350 556 1184 M83-303 222 199 and I want to make it like this M83-306 797 M83-312 685 M83-315 ... (9 Replies)
Discussion started by: muhnandap
9 Replies

10. UNIX for Dummies Questions & Answers

Remove a column using vi editor

How do i remove a column using vi editor Assuming the file to be of format 1: 010 0xad45 sp1 - 11:29:51.498583949 500249144 Event1 rst bcfe jhv rgc 456: 010 0xadb sp2 - 11:29:51.498600605 4464 Event0abcrd adabc aasd 45: 010 0x10 sp0 - 11:29:51.498614165 13560 Back adxca... (6 Replies)
Discussion started by: sp0
6 Replies
oakdecode(1)						      General Commands Manual						      oakdecode(1)

NAME
oakdecode - Decode an OAKT printer stream into human readable form. SYNOPSIS
oakdecode [options] <OAKT-file DESCRIPTION
oakdecode decodes an OAKT printer stream into human readable form. An OAKT printer stream is the printer langauge used by the HP Color LaserJet 1500 and other printers. COMMAND LINE OPTIONS
These are the options that can appear on the command line. -d basename Basename of .pbm file for saving decompressed planes. -r basename Basename of .jbg file for saving raw planes -i Suppress display of image records. -o Print file offsets. -D level Set Debug level [0]. EXAMPLES
Decode an OAKT file created by foo2oak. $ oakdecode < testpage.oak 0d(80) 1 OTHER 0c(64) Wed Nov 05 16:30:50 2003 a07d3 100005 32001e 0a(80) testpage.pdf 14(16) (no args) 28(16) Source=Tray1 29(80) PaperType=0 UNK8=2,0,0,0, blanks(63) 2a(32) Copies=1 UNK=0 2b(32) papercode=25 xwid=4648 ywid=9000 UNK=0 33(64) u0 u1 w h resx resy nBits x0 x0 2128 4300 600 600 x1 15(16) (no args) bih0 w h l0 bih5 dlen plen unk yOff P subP 3c(64) 00010000 2176 256 256 58030020 1050 1056 000 64 3 0 DL = 0, D = 0, P = 1, - = 0, XY = 2176 x 256 L0 = 256, MX = 32, MY = 0 Order = 3 ILEAVE SMID Options = 88 LRLTWO TPDON TPBON 1 stripes, 0 layers, 1 planes 3c(64) 00010000 2176 256 256 58030020 3668 3680 000 320 3 0 3c(64) 00010000 2176 256 256 58030020 1463 1472 000 640 3 0 3c(64) 00010000 2176 256 256 58030020 1975 1984 000 896 3 0 3c(64) 00010000 2176 224 224 58030020 2744 2752 000 1152 3 0 3c(64) 00010000 2176 256 256 58030020 988 992 000 1440 3 0 3c(64) 00010000 2176 256 256 58030020 2892 2896 000 1696 3 0 3c(64) 00010000 2176 256 256 58030020 3634 3648 000 1952 3 0 3c(64) 00010000 2176 256 256 58030020 3236 3248 000 2208 3 0 3c(64) 00010000 2176 256 256 58030020 2279 2288 000 2464 3 0 3c(64) 00010000 2176 256 256 58030020 3746 3760 000 2720 3 0 3c(64) 00010000 2176 200 200 58030020 2404 2416 000 2976 3 0 3c(64) 00010000 2176 256 256 58030020 3114 3120 000 3240 3 0 3c(64) 00010000 2176 96 96 58030020 1142 1152 000 3496 3 0 3c(64) 00010000 2176 256 256 58030020 2094 2112 000 3752 3 0 3c(64) 00010000 2176 256 256 58030020 1319 1328 000 4008 3 0 3c(64) 00010000 2176 36 36 58030020 208 224 000 4264 3 0 17(16) (no args) 18(16) UNK=0 0b(16) (no args) FILES
/usr/bin/oakdecode SEE ALSO
foo2oak-wrapper(1), foo2oak(1), jbg2pbm(1) AUTHOR
Rick Richardson <rick.richardson@comcast.net> http://foo2oak.rkkda.com/
All times are GMT -4. The time now is 01:00 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy