Thank you Don,
I am trying to gather imdb details of some movies.
Regarding, your first answer, it works for the first line of keywords file but no problem..
Regarding your next answer, python test.py > keywords also reads only first line but no problem.
I can solve it.
PS: Changed like this way:
If I do not delete active line after the process, script reads only one line and stops. That's why I used sed
Thank you so much
Boris
Hi
I have a file with lots of line feeds and form feeds (page break). Need to replace last occurrence of form feed (created by - echo "\f" ) in the file with line feed.
Please advise how can i achieve this.
TIA
Prvn (5 Replies)
I have a file with varying record length in it. I need to reformat this file so that each line will have a length of 100 characters (99 characters + the line feed).
AU * A01 EXPENSE 6990370000 CWF SUBC TRAVEL & MISC
MY * A02 RESALE 6990788000 Y... (3 Replies)
Hi ,
I am trying to write an shell, which reads a text file (from a location) having a list of numbers of strictly 5 digits only ex: 33144
Now my script will check :
1) that each entry is only 5 digits & numeric only, no alphabets, & its not empty.
2)then it executes a shell script called... (8 Replies)
I need some advice, I have live feed containing xml messages which means there is new messages every minute. I need a script that will run every 2 hours using the current time minus 2 hours ( which I able to do) However I have problem with the date formatting i.e.
One date is... (3 Replies)
Hi all
I have spent half a day trying to create a shell script which reads a configuration file on a line by line basis.
The idea of the file is that each will contain server information, such as IP address and various port numbers. The line could also be blank (The file is user created). Here... (1 Reply)
Hi! I have been struggling with a large file that has stray end of line characters.
I am working on a Mac (Lion). I mention this only because I have been mucking around with fixing my problem using sed, and I have learned far more than I wanted to know about Unix and Mac eol characters.
I... (1 Reply)
I am working on requirement on spreadsheet in python scripting.
I have a spreadsheet containing cell values and with background color.
I am able to read the value value but unable to get the background color of that particular cell.
Actually my requirement is to read the cell value along... (1 Reply)
i have a text file as belows, it includes 2 columns, 1st is the column name, 2nd is the file_name
data_file.txt
column_name file_name
col1 file1
col2 file2
col3 file1
col4 file1
col5 file2
now, i would like to... (4 Replies)
Discussion started by: tester111
4 Replies
LEARN ABOUT DEBIAN
replacekey
replacekey(1) General Commands Manual replacekey(1)NAME
replacekey - replace keywords in a FITS header
SYNOPSIS
replacekey [options] <in>
DESCRIPTION
replacekey is aimed at replacing keywords in a FITS file's header by new keywords provided by the user on the command-line.
ALGORITHM
The user can provide a new_keyword, an old_keyword, a value and a comment. first searchs for old_keyword if provided. If it finds it, it
replaces the associated card by the new one (new_keyword=value/comment). If old_keyword is either not found or not provided, associated
card by the new one (new_keyword=value/comment). new_keyword has to be provided.
Examples: You want to change the value of VALUE from 32 to 16 in myfile.fits: % replacekey -k "VALUE" -v "16" myfile.fits
If you want to replace the card with the keyword OLD by "NEW = 3.14 / This is a usefull key" in myfile.fits: % replacekey -k "NEW" -v
"3.14" -c "This is a usefull key" -K "OLD" myfile.fits
If your do not care about the HISTORY cards you have in the header, and want to replace the first one by VALUE=32, you would do:
% replacekey -k "VALUE" -v "32" -K "HISTORY" myfile.fits
OPTIONS -k or --key key
To provide the new keyword.
-K or --old key
To provide the old keyword.
-v or --val val
To provide the new value.
-c or --com com
To provide the new comment.
SEE ALSO
hierarch28 to convert HIERARCH ESO keywords to regular 8-char keywords.
FILES
Files shall all comply with FITS format
BUGS
Modifications are so far only possible in the main header, not in the extensions.
28 Oct 1999 replacekey(1)