Sponsored Content
Top Forums UNIX for Dummies Questions & Answers putting a timestamp in a file Post 42117 by rocker40 on Wednesday 22nd of October 2003 11:56:44 AM
Old 10-22-2003
works great

date >> {filename}
I feel so low Smilie I should have thought of that
Thank you
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

putting restrictions when copying file

I would like to create a command to copy a file with a restriction- if the file exists at the copy destination, the copy does not occur and message is provided that file already exists. (3 Replies)
Discussion started by: thoffpauir
3 Replies

2. Shell Programming and Scripting

Putting screen output in a log file

I want to output screen messages to a logfile when executing an automated script. I have tried the script and command to do this but with no luck. Thanks, Nicole (5 Replies)
Discussion started by: nsutti
5 Replies

3. Shell Programming and Scripting

Separating values from a file and putting to a variable

I am writing into a file testfile.txt values like ./XXXXXXCZ1/tprcm10c.bin ./XXXXXXCZ1_HOT/tprcm09c.bin ./XXXXXXCZ_cold/tprcm05c.bin I want to store the values of tprcm*.bin and XXXXXXCZ* in separate variables Can anybody Pls hlp me out with this ... Thanks (2 Replies)
Discussion started by: ultimatix
2 Replies

4. UNIX for Dummies Questions & Answers

Putting echoed text into a new file

Hi, I've set up a script so that a user answers questions, and then these answers come back onto the screen accompanied by text that I've echoed. Is there a way of putting this into a new file? Thanks (7 Replies)
Discussion started by: likelylad
7 Replies

5. Shell Programming and Scripting

Getting a relative timestamp from timestamp stored in a file

Hi, I've a file in the following format 1999-APR-8 17:31:06 1500 3 45 1999-APR-8 17:31:15 1500 3 45 1999-APR-8 17:31:25 1500 3 45 1999-APR-8 17:31:30 1500 3 45 1999-APR-8 17:31:55 1500 3 45 1999-APR-8 17:32:06 1500 3 ... (1 Reply)
Discussion started by: vaibhavkorde
1 Replies

6. UNIX for Dummies Questions & Answers

How to compare a file by its timestamp and store in a different location whenever timestamp changes?

Hi All, I am new to unix programming. I am trying for a requirement and the requirement goes like this..... I have a test folder. Which tracks log files. After certain time, the log file is getting overwritten by another file (randomly as the time interval is not periodic). I need to preserve... (2 Replies)
Discussion started by: mailsara
2 Replies

7. Shell Programming and Scripting

Putting together all values from different files in one file

Hi All, This is what I am trying to achieve but to no avail. I have three sets of files which are: 1. One big dictionary file which looks like this: apple orange computer pear country 2. Some thousands of text files which are named as 1.dat, 2.dat, 3.dat etc The text files... (2 Replies)
Discussion started by: shoaibjameel123
2 Replies

8. UNIX for Dummies Questions & Answers

Putting the Current -date in the Output File

Hi guys, Just want to ask how can I make a script that will perform like this. 1. Execute the command 2. Then the output of the command will be redirected to a file 2. The file that has been created will have a date on it equivalent to the date and time it was created (or maybe after the... (5 Replies)
Discussion started by: rymnd_12345
5 Replies

9. Shell Programming and Scripting

Putting a separator in file using awk/bash

I have a file with the following content: a-123-345-232 a-23343-4545-545 a-67676-45454-8787 a-129-8912-9824 b-564-78678-2322 b-5454-76767-8899 b-85554-124-152-29 c-34534-654543-323 (... and so on, actually these are pretty huge records) Now, I want that the file should not be broken in to... (8 Replies)
Discussion started by: askerbis
8 Replies

10. Shell Programming and Scripting

Need help in sorting the file and putting to a different folder

Hi, I am new to unix. Kindly help me on this. My requirement is as below: I have a path temp/input , temp/CL and temp/CM I have files in temp/input as below (dates in YYYYMMDDHHMISS) NMP1515O.CL.20181026111213 NMP1515O.CM.20181025111213 ... (4 Replies)
Discussion started by: Shanmugapriya D
4 Replies
curs_scr_dump(3CURSES)					     Curses Library Functions					    curs_scr_dump(3CURSES)

NAME
curs_scr_dump, scr_dump, scr_restore, scr_init, scr_set - read or write a curses screen from or to a file SYNOPSIS
cc [ flag ... ] file ... -lcurses [ library ... ] #include <curses.h> int scr_dump(char *filename); int scr_restore(char *filename); int scr_init(char *filename); int scr_set(char *filename); DESCRIPTION
With the scr_dump() routine, the current contents of the virtual screen are written to the file filename. With the scr_restore() routine, the virtual screen is set to the contents of filename, which must have been written using scr_dump(). The next call to doupdate() restores the screen to the way it looked in the dump file. With the scr_init() routine, the contents of filename are read in and used to initialize the curses data structures about what the terminal currently has on its screen. If the data is determined to be valid, curses bases its next update of the screen on this information rather than clearing the screen and starting from scratch. scr_init() is used after initscr() or a system(3C) call to share the screen with another process which has done a scr_dump() after its endwin() call. The data is declared invalid if the time-stamp of the tty is old or the terminfo capabilities rmcup() and nrrmc() exist. The scr_set() routine is a combination of scr_restore() and scr_init(). It tells the program that the information in filename is what is currently on the screen, and also what the program wants on the screen. This can be thought of as a screen inheritance function. To read (write) a window from (to) a file, use the getwin() and putwin() routines (see curs_util(3CURSES)). RETURN VALUES
All routines return the integer ERR upon failure and OK upon success. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |MT-Level |Unsafe | +-----------------------------+-----------------------------+ SEE ALSO
curs_initscr(3CURSES), curs_refresh(3CURSES), curs_util(3CURSES), curses(3CURSES), system(3C), attributes(5) NOTES
The header <curses.h> automatically includes the headers <stdio.h> and <unctrl.h>. Note that scr_init(), scr_set(), and scr_restore() may be macros. SunOS 5.11 31 Dec 1996 curs_scr_dump(3CURSES)
All times are GMT -4. The time now is 10:54 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy