06-03-2008
How to remove date and page header from a printout
I have some HP4+ and HP5 printers printing from Unixware 7.1.4. The problem is that they print a page header with the date and page number. I can't seem to figure out how to stop this. These headers through the pagination off.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I would like to remove some lines from begining of file (header) and some lines from end of file (footer).
The header/footer lines generated by web-browser when the user upload a file to my webserver.
Example:
-----------------------------7d62af20c052c
Content-Disposition: form-data;... (2 Replies)
Discussion started by: seaky
2 Replies
2. Shell Programming and Scripting
Hi All,
I get a flat file with its last field data splitting onto a new line.I got this program from Vgersh which when run would cancatenate the split data back to the end of the previous records.But this program fails when it encounters a page break between the split data and the previous... (5 Replies)
Discussion started by: kumarsaravana_s
5 Replies
3. UNIX for Dummies Questions & Answers
I need to concatenate about a thousand files (using a loop) on a UNIX server. Also, each file has a header row which is to be removed. Which of the following would give better performance?
tail+2 <filename> or sed '1,1d' <filename>
Or is there another, faster way?
Thanks,
Kaus (4 Replies)
Discussion started by: kausmone
4 Replies
4. Shell Programming and Scripting
Hi,
I'm ssh'ing into a server using ruby and sending a one-liner to retrieve the output of the 'ps aux' command. So far, this is what I have:
ps aux | sort -r -n -k3 | sed -e '1s/^/this is first\n/' | head -n10
With this I can insert a line at position 1, but I would rather extract the... (3 Replies)
Discussion started by: gekeha
3 Replies
5. Shell Programming and Scripting
Hi,
I am trying to write a code for changing header date of a file with a date of 6 month back.
Below is the header date on which I am working -
20080531
I want to change it as 20071130
Please suggest me in the way like ,I can change any date in a file with date of 6 months back.
... (9 Replies)
Discussion started by: Monalisa
9 Replies
6. Shell Programming and Scripting
Hi Friends thanks a lot....for ur replies its worked fine...i have one more question..
if i need to remove trailor (T000000004 ) as shown below file also with header.Plz help thanks
Source file:
H20100928
D04041201609360677PC790010384I
D04041203326357853PC790010645R ... (1 Reply)
Discussion started by: dprakash
1 Replies
7. UNIX for Dummies Questions & Answers
I want to delete the header and footer in the file by using sed for that i ran the below script and my text file looks like
emp.txt
# This file contain employee
# information
abc 12300 34 'FGH'
# This is confidential as per the firm rules.
my intention is to remove the header... (8 Replies)
Discussion started by: vmachava
8 Replies
8. Programming
it still display header and footer
header
SQL*Plus: Release 10.2.0.1.0 - Production on Mon Sep 24 13:41:51 2012
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64bit Production
With the Partitioning, Real... (0 Replies)
Discussion started by: ment0smintz
0 Replies
9. Shell Programming and Scripting
Hi Team,
I'm looking for a command which removes files having 0 byte of having only header line (1 line).
My ETL process generates these files. Few files are not having header, in that case if no data from source, it will be 0 byte and few files are having header, in that case if no data from... (7 Replies)
Discussion started by: ace_friends22
7 Replies
10. Shell Programming and Scripting
Hi Guys,
I have below directory where there are certain files. Something like below
country_dir
aus_01.txt
nz_01.txt
aus_02.txt
bd.txt
property.txt
aus
nz
bd
I need to remove the header of the file which ends with _01.txt while copying from country directory to another... (15 Replies)
Discussion started by: rohit_shinez
15 Replies
PR(1) User Commands PR(1)
NAME
pr - convert text files for printing
SYNOPSIS
pr [OPTION]... [FILE]...
DESCRIPTION
Paginate or columnate FILE(s) for printing.
With no FILE, or when FILE is -, read standard input.
Mandatory arguments to long options are mandatory for short options too.
+FIRST_PAGE[:LAST_PAGE], --pages=FIRST_PAGE[:LAST_PAGE]
begin [stop] printing with page FIRST_[LAST_]PAGE
-COLUMN, --columns=COLUMN
output COLUMN columns and print columns down, unless -a is used. Balance number of lines in the columns on each page
-a, --across
print columns across rather than down, used together with -COLUMN
-c, --show-control-chars
use hat notation (^G) and octal backslash notation
-d, --double-space
double space the output
-D, --date-format=FORMAT
use FORMAT for the header date
-e[CHAR[WIDTH]], --expand-tabs[=CHAR[WIDTH]]
expand input CHARs (TABs) to tab WIDTH (8)
-F, -f, --form-feed
use form feeds instead of newlines to separate pages (by a 3-line page header with -F or a 5-line header and trailer without -F)
-h, --header=HEADER
use a centered HEADER instead of filename in page header, -h "" prints a blank line, don't use -h""
-i[CHAR[WIDTH]], --output-tabs[=CHAR[WIDTH]]
replace spaces with CHARs (TABs) to tab WIDTH (8)
-J, --join-lines
merge full lines, turns off -W line truncation, no column alignment, --sep-string[=STRING] sets separators
-l, --length=PAGE_LENGTH
set the page length to PAGE_LENGTH (66) lines (default number of lines of text 56, and with -F 63). implies -t if PAGE_LENGTH <= 10
-m, --merge
print all files in parallel, one in each column, truncate lines, but join lines of full length with -J
-n[SEP[DIGITS]], --number-lines[=SEP[DIGITS]]
number lines, use DIGITS (5) digits, then SEP (TAB), default counting starts with 1st line of input file
-N, --first-line-number=NUMBER
start counting with NUMBER at 1st line of first page printed (see +FIRST_PAGE)
-o, --indent=MARGIN
offset each line with MARGIN (zero) spaces, do not affect -w or -W, MARGIN will be added to PAGE_WIDTH
-r, --no-file-warnings
omit warning when a file cannot be opened
-s[CHAR], --separator[=CHAR]
separate columns by a single character, default for CHAR is the <TAB> character without -w and 'no char' with -w. -s[CHAR] turns
off line truncation of all 3 column options (-COLUMN|-a -COLUMN|-m) except -w is set
-S[STRING], --sep-string[=STRING]
separate columns by STRING, without -S: Default separator <TAB> with -J and <space> otherwise (same as -S" "), no effect on column
options
-t, --omit-header
omit page headers and trailers; implied if PAGE_LENGTH <= 10
-T, --omit-pagination
omit page headers and trailers, eliminate any pagination by form feeds set in input files
-v, --show-nonprinting
use octal backslash notation
-w, --width=PAGE_WIDTH
set page width to PAGE_WIDTH (72) characters for multiple text-column output only, -s[char] turns off (72)
-W, --page-width=PAGE_WIDTH
set page width to PAGE_WIDTH (72) characters always, truncate lines, except -J option is set, no interference with -S or -s
--help display this help and exit
--version
output version information and exit
AUTHOR
Written by Pete TerMaat and Roland Huebner.
REPORTING BUGS
GNU coreutils online help: <http://www.gnu.org/software/coreutils/>
Report pr translation bugs to <http://translationproject.org/team/>
COPYRIGHT
Copyright (C) 2017 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.
SEE ALSO
Full documentation at: <http://www.gnu.org/software/coreutils/pr>
or available locally via: info '(coreutils) pr invocation'
GNU coreutils 8.28 January 2018 PR(1)