As the title suggests, i am having some trouble figuring out how to pass spaces and carriage returns to a 'here document' ie
#!/bin/bash
/usr/local/install_script.sh <<SCRIPT
yes
no
<pass carriage retun here>
yes
no
<pass a space and then a carriage return here>
exit
SCRIPT
any... (0 Replies)
How do we delete all carriage returns after a particular string using sed inside a K Shell?
e.g. I have a text file named file1 below:
$ more file1
Group#=1 User=A
Role=a1
Group#=2 User=B
Role=a1
Role=b1
Group#=3 User=C
Role=b1
I want the carriage returns to be delete on the... (12 Replies)
I need to replace thousands of carriage returns/line breaks in a large xml file and with spaces. I hope to do so with a script, called, for example, "removeCRs." I would invoke this at the command line as
ml5003$ sed -f /Users/ml5003/removeCRs oldFile > newFile
The script, I presume, would... (4 Replies)
Hello, I have read a few threads on this subject and tried a few things out, but still come up short.
There was one good example, then the last reply was something to the effect of 'Use Sed' & 'Read a book'...
Well I read a bunch of online tutorials on sed, awk, tr, but still can't get the... (2 Replies)
Hi,
I've got an issue with a shell script that FTP's a file from one Linux server to another Linux server.
My script runs on a Linux server and creates an output file (from a database call), and then FTP's this file to another Linux server.
The problem is that, even though the output file... (0 Replies)
Hi,
I have a file which is having some carriage return in one of the field for which single line is coming in multiple lines.
I want to combine all those multiple lines of that field into one line.
Eg:
Input:
Id, Name, Location, Comments, Dept
2, John, US, I am from US.
I... (5 Replies)
I have a directory of over a hundred text files that I'm getting ready to merge with the CAT command. However there is only one space after each file; this makes the output look crowded.
I would like to add two, possibly even four carriage returns at the end of each text file to make the final... (2 Replies)
I have a CSV with carriage returns in place of newlines. I am trying to use tr to remove them, but it isn't working.
Academic year,Term,Course name,Period,Last name,Nickname
2012-2013,First Semester,English 12,4th Period,Arnold,Adam
2012-2013,First Semester,English 12,4th Period,Adams,Jim... (1 Reply)
I'm on Linux version 2.6.32-696.3.1.el6.x86_64, using the Ksh shell.
I'm working with the input file:
John Daggett, 341 King Road, Plymouth MA
Alice Ford, 22 East Broadway, Richmond VA
Orville Thomas, 11345 Oak Bridge Road, Tulsa OK
Terry Kalkas, 402 Lans Road, Beaver Falls PA
Eric Adams,... (2 Replies)
Discussion started by: prooney
2 Replies
LEARN ABOUT HPUX
asa
asa(1) General Commands Manual asa(1)NAME
asa - interpret ASA carriage control characters
SYNOPSIS
[files]
DESCRIPTION
interprets the output of FORTRAN programs that utilize ASA carriage control characters. It processes either the files whose names are
given as arguments, or the standard input if is specified or if no file names are given. The first character of each line is assumed to be
a control character. The following control characters are interpreted as indicated:
(blank) Output a single new-line character before printing.
(space) (UNIX Standard only, see standards(5)) The rest of the line will be output without change.
A <newline> shall be output, then the rest of
the input line.
Output a new-page character before printing.
Overprint previous line.
(UNIX Standard only, see
standards(5)) The <newline> of the previous line shall be replaced with one or more implementation-defined characters that
causes printing to return to column position 1, followed by the rest of the input line. If the + is the first character in
the input, it shall have the same effect as <space>.
Lines beginning with other than the above characters are treated the same as lines beginning with a blank. The first character of a line
is printed. If any such lines appear, an appropriate diagnostic is sent to standard error. This program forces the first line of each
input file to start on a new page.
(UNIX Standard only, see standards(5)) The action of the asa utility is unspecified upon encountering any character other than those listed
above as the first character in a line.
To view the output of FORTRAN programs which use ASA carriage control characters and have them appear in normal form, can be used as a fil-
ter:
The output, properly formatted and paginated, is then directed to the line printer. FORTRAN output previously sent to a file can be viewed
on a user terminal screen by using:
EXTERNAL INFLUENCES
For information about the UNIX standard environment, see standards(5).
Environment Variables
determines the interpretation of text within file as single- and/or multi-byte characters.
determines the language in which messages are displayed.
If or is not specified in the environment or is set to the empty string, the value of is used as a default for each unspecified or empty
variable. If is not specified or is set to the empty string, a default of "C" (see lang(5)) is used instead of
If any internationalization variable contains an invalid setting, behaves as if all internationalization variables are set to "C". See
environ(5).
International Code Set Support
Single- and multi-byte character code sets are supported.
SEE ALSO efl(1), f77(1), ratfor(1), standards(5).
STANDARDS CONFORMANCE asa(1)