10-17-2015
Quote:
Originally Posted by
la2015
Brilliant, thank you all.
@DonCragun, why do you say there were no tabs in my sample? I made it with a vi editor, and I actually used a tab separator. Just curious..
I say there were no tabs in your sample because the text you included in post #5 and post #7 in this thread did not contain any <tab> characters.
Note that if you copy text from a terminal emulator window in which you are running
vi,
vi uses spaces instead <tab>s to display <tab> characters. On most systems, if you exit
vi and
cat the file to the screen, you can then copy the text from your terminal emulator window and paste it into a post on this forum to have <tab>s appear as <tab>s (ass long as you post those sample inside CODE tags).
9 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I have a file that looks like this:
G. KRESSLAR
9618 W. APPALOOSA DRIVE
SUN CITY, AZ 85373
SHIRLEY ALLEN
7272 W. VIA MONTOYA DRIVE
GLENDALE, AZ 85310
LOUIS VALDEZ
244441 N. 86TH AVENUE
PEORIA, AZ 85383
DONNA NEWBON
3231 W. DENTON #D
PHOENIX, AZ 85017
SARAH WILSON
6534 W. PALO... (3 Replies)
Discussion started by: BCarlson
3 Replies
2. Shell Programming and Scripting
HI guys,
I have created a script to read 1 column in a csv file and then place it in text file.
However, when i checked out the text file, it is not in a column format...
Example:
CSV file contains
name,age
aa,11
bb,22
cc,33
After using awk to get first column
TXT file... (1 Reply)
Discussion started by: mdap
1 Replies
3. Shell Programming and Scripting
Hi everybody
I want to manipulate the output of this command: df -h to something like this:
df -h | awk '{print"\t\t "$1"\t\t"$6"\t\t"$2"\t\t" $4}' | sed 's/Mounted/Mount Point/g' | sed 's/Avail/Free Space/g'but my problem is: if for example the mounting point is a long name everything beside... (3 Replies)
Discussion started by: ialbert
3 Replies
4. Shell Programming and Scripting
HI Pros,
I have a issue.I need to write a script to parse the logs got from syslog server and update the same in my database.I need the following output.I donot know perl and I heard it very easy to write in perl
I have the sample log I need each column seperated by commas and all equals... (0 Replies)
Discussion started by: iron_michael86
0 Replies
5. Shell Programming and Scripting
I need a script that takes it input wither it be from a file or inputed as variables and sort that into three columns. Thanks (3 Replies)
Discussion started by: prottheman
3 Replies
6. Shell Programming and Scripting
I have prepared a script to submit a string in a txt file.
However there are somethings that I have to check before submitting the string in the txt file.
One of those checks is to determine whether the string entered contains any metacharacters.
I have tried sth like;
echo "string" | grep -v ... (3 Replies)
Discussion started by: ozum
3 Replies
7. UNIX for Dummies Questions & Answers
Hi,
I have a very large file which is of the general format:
0 3 4 2 ...
3 2 4 0 ...
0 3 4 2 ...
3 0 4 2 ...
. . . . ...
. . . . ...
I would like to apply a simple awk/sed script to work out whether there are any 2's, 3's and 4's in each column.
The results would look as... (3 Replies)
Discussion started by: kasan0
3 Replies
8. Shell Programming and Scripting
Possible filenames:
CDD_Whatever.txt
DDD_Whatever.txt
If the file prefix = CDD, I'd like to prefix every person ID (second column in my examples below) on the file with "c-"
If the file prefix = DDD, I'd like to prefix ever person ID with "d-"
Input:
Desired Output:
Any help... (2 Replies)
Discussion started by: lrluis
2 Replies
9. Shell Programming and Scripting
Hi I have an XML File with default header($ lines of data) and default tail (Two Lines) and the body has occurrence of start<Folder> and ends with </Folder>.
Now i want to split each occurrence i mean each start and end in to separate files with header and tail.
For example:
header line... (12 Replies)
Discussion started by: Nithin Kumar
12 Replies
LEARN ABOUT REDHAT
phosphor
XScreenSaver(1) General Commands Manual XScreenSaver(1)
NAME
phosphor - simulates an old terminal with long-sustain phosphor
SYNOPSIS
phosphor [-display host:display.screen] [-window] [-root] [-install] [-visual visual] [-font font] [-scale int] [-ticks int] [-delay usecs]
[-program command]
DESCRIPTION
The phosphor program draws text on the screen in a very large pixellated font that looks like an old low resolution dumb tty. The pixels
flare and fade out as if the phosphor was very long-sustain.
OPTIONS
phosphor accepts the following options:
-window Draw on a newly-created window. This is the default.
-root Draw on the root window.
-install
Install a private colormap for the window.
-visual visual
Specify which visual to use. Legal values are the name of a visual class, or the id number (decimal or hex) of a specific visual.
-font font-name
The X font to use. Phosphor can take any font and scale it up to pixellate it. The default is fixed.
-scale int
How much to scale the font up: in other words, the size in real pixels of the simulated pixels. Default 6.
-ticks int
The number of colors to use when fading to black. Default 20.
-delay usecs
The speed of the terminal: how long to wait between drawing each character. Default 50000, or about 1/20th second.
-program sh-command
The command to run to generate the text to display. This option may be any string acceptable to /bin/sh. The program will be run
at the end of a pipe, and any characters that it prints to stdout will be printed on phosphor's window. The characters will be
printed artificially slowly, as per the -delay option above. If the program exits, it will be launched again after 5 seconds.
Note that phosphor is not a terminal emulator: programs that try to directly address the screen will not do what you might expect.
Phosphor merely draws the characters on the screen left to right, top to bottom. Lines wrap when they reach the right edge, and
the screen scrolls when characters reach the bottom.
In other words, programs like fortune(1) will work, but programs like top(1) won't.
Here's a good trick, to get phosphor to display recent web search terms:
phosphor -program
'wget -qO- http://webcrawler.com/cgi-bin/SearchTicker'
ENVIRONMENT
DISPLAY to get the default host and display number.
XENVIRONMENT
to get the name of a resource file that overrides the global resources stored in the RESOURCE_MANAGER property.
SEE ALSO
wget(1), X(1), xscreensaver(1)
COPYRIGHT
Copyright (C) 1999 by Jamie Zawinski. Permission to use, copy, modify, distribute, and sell this software and its documentation for any
purpose is hereby granted without fee, provided that the above copyright notice appear in all copies and that both that copyright notice
and this permission notice appear in supporting documentation. No representations are made about the suitability of this software for any
purpose. It is provided "as is" without express or implied warranty.
AUTHOR
Jamie Zawinski <jwz@jwz.org>, 27-Apr-99.
X Version 11 30-Oct-99 XScreenSaver(1)