Sponsored Content
Full Discussion: AWK & FILENAME
Top Forums UNIX for Dummies Questions & Answers AWK & FILENAME Post 302567571 by Corona688 on Monday 24th of October 2011 11:51:27 AM
Old 10-24-2011
FILENAME is a special variable and already set, incrementing it won't tag a "1" on the end.

How about FILENAME "." N++
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Sort files by Date-timestamps available in filename & pick the sortedfiles one by one

Hi, I am new to Unix shell scripting. Can you please help me with this immediate requirement to code.. The requirement is as given below. In a directory say Y, I have files like this. PP_100000_28062006_122731_746.dat PP_100000_28062006_122731_745.dat PP_100000_28062006_122734_745.dat... (4 Replies)
Discussion started by: Chindhu
4 Replies

2. Shell Programming and Scripting

Getting modified time & filename only

Hi, When we use "ls -l" we are getting like below, -rw-r--r-- 1 mdskl mds 4161479 Apr 12 14:57 VTTF2008.20080412145748.cc But i need only modified time and filename only like below, Apr 12 14:57 VTTF3008.20080412145748.cc Thanks-:) Senthil (4 Replies)
Discussion started by: senthil_seera
4 Replies

3. Shell Programming and Scripting

gzcat into awk and then change FILENAME and process new FILENAME

I am trying to write a script that prompts users for date and time, then process the gzip file into awk. During the ksh part of the script another file is created and needs to be processed with a different set of pattern matches then I need to combine the two in the end. I'm stuck at the part... (6 Replies)
Discussion started by: timj123
6 Replies

4. Shell Programming and Scripting

find and replace in subdirectory (filename & content - both)

Hi, I have to rename all occurance of CUST_MST to RESELLER_MST both in filename and file content under a directory (say D0) which contains multiple (2-3 levels) sub directory. Example: D0 -> D1 -> D2 has a file CUST_MST_TEMP.txt this contains : > cat /D0/D1/D2/CUST_MST_TEMP.txt... (3 Replies)
Discussion started by: sabyasm
3 Replies

5. UNIX for Dummies Questions & Answers

Adding Date & time stamps to filename

I need to edit the file name with date and time while writing the script. please help. (1 Reply)
Discussion started by: manish.s
1 Replies

6. Shell Programming and Scripting

Filename & Owner

Hi all! I'm trying to write a script that joins the filename and the owner (e.g. .profile_root , home_smith) Is there a easy way to do it. I've been trying with a for and playing with ls and head & tail. I would attach what I've had done but is very ugly:o (1 Reply)
Discussion started by: funyotros
1 Replies

7. Shell Programming and Scripting

Korn Shell & Nawk...Filename changes

I have the following piece of code: YESTER=`TZ=aaa24 date +%b"-"%d` filelist2=$(find /export/home/gen/check/logs \( -name \*$YESTER\* ! -name \*ADM\* \) -print | tr '\n' ' ') nawk -F':' ' $2 ~ /Reason/ && $3 !~ /(PASSTHRU|OCAP|FP Power Button|Bootloader Reset)/ { split(FILENAME,... (2 Replies)
Discussion started by: ther2000
2 Replies

8. Shell Programming and Scripting

[Beginner's questions] Filename Validation & Parsing

Hi !! I'm rather new both to the UNIX and scripting worlds, and I'm learning the ropes of scripting. Having said this, please excuse me if you notice certain basic errors. I'm working on a script that implements .jar and .war files for a WAS environment and I need to perform certain... (4 Replies)
Discussion started by: levaldez
4 Replies

9. Shell Programming and Scripting

awk Help: quick and easy question may be: How to use &&

Hi Guru's. I am trying to use to check if $5 is greater than 80 & if not 100, then to print $0 : awk '{ if ($5>80) && if ($5 != 100) print $0} But getting error: >bdf1|sed 's/%//g'|awk '{ if ($5>80) && if ($5 != 100) print $0}' syntax error The source line is 1. The error... (6 Replies)
Discussion started by: rveri
6 Replies

10. UNIX for Dummies Questions & Answers

How to find a file based on pattern & return the filename if found?

Hi all, I am a newbie here. I have this requirement to find a file based on a pattern then return the filename if found. I created a script based on online tutorials. Though, I am stuck & really appreciate if anyone can have a quick look & point me to the right direction? #Script starts... (10 Replies)
Discussion started by: buster_t
10 Replies
edfhed(1)							     Aghermann								 edfhed(1)

NAME
edfhed -- EDF header dumper/editor. SYNOPSIS
edfhed [OPTIONS] file.edf ... DESCRIPTION
edfhed is a terminal program to view the header of EDF files (with option -b, or none), or modify fields in the header (see options -s, -T and -R). -b, --no-channels Only dump general header fields (no channel details). -R, --from-tree Given file location Subject/Session/Episode.edf, set recording_id to 'Session/Episode' and patient_id to 'Subject'. -T, --from-mtime Set 'recording_date' and 'recording_time' fields to file modification date/time. -t, --touch-mtime Set file mtime to timestamp assembled from 'recording_date' and 'recording_time' fields (assuming local timezone). -s, --set=[CH:]FIELD:VALUE Set FIELD to VALUE (in channel CH if specified, as a 1-based integer index). Possible general fields are: version_number (if it ain't broke, don't touch it), patient_id, recording_id, recording_date, record- ing_time, reserved (remember that the contents of this field is significant wrt EDF/EDF+ distinction). Channel fields: label, transducer_type, physical_dim, physical_min, physical_max, digital_min, digital_max, filtering_info, reserved. Direct field assignment done via --set option(s) will override any assignments effected by options -T or -R. -?, --help Give this help list --usage Give a short usage message USE WITH AGHERMANN
For Aghermann to be able to manage an EDF file, all relevant fields in its header must be filled out correctly, as folllows: o patient_id uniquely identifies the Subject; o recording_id identifies the recording session (out of several other such sessions, each containing the same series of episodes) and the individual episode. These two items must appear in one of the following combinations: o "Session/Episode" o "Session : Episode" o "Episode (Session)" o recording_date and recording_time must (obviously) be both correct. o Channel labels must be a valid System 10-20 channel designation, i.e., "Nz", "Fp1", "Fpz", "Fp2", "AF7", "AF3", "AFz", "AF4", "AF8", "F9", "F7", "F5", "F3", "F1", "Fz", "F2", "F4", "F6", "F8", "F10", "FT9", "FT7", "FC5", "FC3", "FC1", "FCz", "FC2", "FC4", "FC6", "FCT8", "FT10", "A1", "T9", "T7", "C5", "C3", "C1", "Cz", "C2", "C4", "C6", "T8", "T10", "A2", "TP9", "TP7", "CP5", "CP3", "CP1", "CPz", "CP2", "CP4", "CP6", "TP8", "TP10", "P9", "P7", "P5", "P3", "P1", "Pz", "P2", "P4", "P6", "P8", "P10", "PO7", "PO3", "POz", "PO4", "PO8", "O1", "Oz", "O2", "Iz", plus a few channels of other signal types: "Left", "Right", "Chin", optionally prepended by signal type ("EEG", "EOG", "EMG", "ECG", "ERG", "NC", "MEG", "MCG", "EP", "Temp", "Resp", "SaO2", "Light", "Sound", "Event", "Freq") and a space. SEE ALSO
aghermann(1), edfhed-gtk(1). AUTHOR
edfhed is written by Andrei Zavada <johnhommer@gmail.com> as part of the Aghermann project. 0.6.0.1 2012-06-04 edfhed(1)
All times are GMT -4. The time now is 09:22 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy