Sponsored Content
Top Forums Shell Programming and Scripting Until the file extension matches Post 302193053 by Sreejith_VK on Thursday 8th of May 2008 11:16:15 AM
Old 05-08-2008
Network Curious error

ksh. And
Quote:
==
is throwing the following error:

Quote:
==: unknown test operator
One more issue the "" worked only first time..
That is when I gave .dmp after accessing the script for the first time it goes through and comes to next step.
but when I gave .dmp again after an error it again throwed error Smilie
Sreejith_VK
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

find matches in file

Hi, im have log file ~100000 lines, 192.168.29.1 at 10/08/09 13:58:55 192.168.60.1 at 10/08/09 14:11:28 192.168.58.171 at 10/08/09 14:12:45 192.168.61.12 at 10/08/09 14:15:44 192.168.60.1 at 10/08/09 14:16:36 192.168.60.1 at 10/08/09 14:17:43 192.168.61.12 at 10/08/09 14:18:08... (9 Replies)
Discussion started by: Trump
9 Replies

2. Shell Programming and Scripting

get value that matches file name pattern

Hi I have files with names that contain the date in several formats as, YYYYMMDD, DD-MM-YY,DD.MM.YY or similar combinations. I know if a file fits in one pattern or other, but i donīt know how to extract the substring contained in the file that matches the pattern. For example, i know that ... (1 Reply)
Discussion started by: pjrm
1 Replies

3. UNIX for Dummies Questions & Answers

creating separate directories according to file extension and keeping file in different directory as

unix program to which a directory name will be passed as parameter. This directory will contain files with various extensions. This script will create directories with the names of the extention of the files and then put the files in the corresponding folder. All files which do not have any... (2 Replies)
Discussion started by: Deekay.p
2 Replies

4. UNIX for Dummies Questions & Answers

Pipe binary file matches grep results to file

I am using grep to match a pattern, but the output is strange. $ grep -r -o "pattern" * Gives me: Binary file foo1 matches Binary file foo2 matches Binary file foo3 matches To find the lines before/after, I then have to use the following on each file: $ strings foo1 | grep -A1 -B1... (0 Replies)
Discussion started by: chipperuga
0 Replies

5. Shell Programming and Scripting

regex matches from lines in file

Hello, I try to script something (bash-script) and can not find a way to get and store a match into a variable from a line in a file. grep isn't useful as the matches are not returned - just colored. I can't get 'expr' to work for me. Is it necessary to use a perl-script with regex instead? ... (7 Replies)
Discussion started by: daWonderer
7 Replies

6. Shell Programming and Scripting

Compare 2 files and print matches and non-matches in separate files

Hi all, I have two files, chap.txt and complex.txt. chap.txt looks like this: a d l m r k complex.txt looks like this: a c d e l m n j a d l p q r c p r m ......... (7 Replies)
Discussion started by: AshwaniSharma09
7 Replies

7. UNIX for Dummies Questions & Answers

Display the .csv extension files based on .done extension fine

Hi All, I want to fetch the files based on .done file and display the .csv files and Wil take .csv files for processing. 1.I need to display the .done files from the directory. 2.next i need to search for the .Csv files based on .done file.then move .csv files for the one directory ... (2 Replies)
Discussion started by: girija.g6
2 Replies

8. Shell Programming and Scripting

FTP a file if the date matches

Hi, I am trying to write a script where I need to pull any file if the date is from yesterday. Can you please help me on how to check the dates for the files on the remote server? Please let me know for any questions. Thanks Ajay (4 Replies)
Discussion started by: ajayakunuri
4 Replies

9. Shell Programming and Scripting

Required 3 lines above the file and below file when string matches

i had requirement like i need to get "error" line of above 3 and below 3 from a file .I tried with the below script.But it's not working. y='grep -n -i error /home/file.txt|cut -c1' echo $y head -$y /home/file.txt| tail -3 >tmp.txt tail -$y /home/file.txt head -3 >>tmp.txt (4 Replies)
Discussion started by: bhas85
4 Replies

10. Shell Programming and Scripting

Rename specific file extension in directory with match to another file in bash

I have a specific set (all ending with .bam) of downloaded files in a directory /home/cmccabe/Desktop/NGS/API/2-15-2016. What I am trying to do is use a match to $2 in name to rename the downloaded files. To make things a more involved the date of the folder is unique and in the header of name... (1 Reply)
Discussion started by: cmccabe
1 Replies
XHPSelectExtensionEvent(3X)											       XHPSelectExtensionEvent(3X)

NAME
XHPSelectExtensionEvent - Select an extension event. SYNOPSIS
int XHPSelectExtensionEvent (display, window, deviceid, mask) Display *display; Window window; XID deviceid; Mask mask; ARGUMENTS
display Specifies the connection to the X server. window Specifies the window from which input is desired. deviceid Specifies the device from which input is desired. mask Specifies the mask of input events that are desired. DESCRIPTION
These requests are part of an HP-proprietary extension to X. Its functionality has been superseded by the standard X input device extension XSelectExtensionEvent request. You should use XSelectExtensionEvent instead of XHPSelectExtensionEvent if possible. This request is provided to support the use of input devices other than the X keyboard and X pointer device. It allows input from other input devices to be selected independently from that coming from the X pointer and keyboard. XHPSelectExtensionEvent requests the server to send an extended event that matches the specified event mask and comes from the specified device and window. In order to use this request, the client program must first determine the appropriate deviceid by using the XHPListInputDevice request, and the appropriate event mask by using the XHPGetExtEventMask request. Multiple event masks returned by XHPGetExtEventMask may be OR'd together and specified in a single request to XHPSelectExtensionEvent. This request cannot be used to select any of the core X events, or to receive input from the X Keyboard or X pointer device. The core XSelectInput request should be used for that purpose. DIAGNOSTICS
BadDevice An invalid device ID was specified. BadWindow An invalid window ID was specified. RETURN VALUE
none FILES
none ORIGIN
Hewlett-Packard Company SEE ALSO
XHPListInputDevices(3x) XHPGetExtEventMask(3x) XSelectInput(3x) X Version 11 Release 5 XHPSelectExtensionEvent(3X)
All times are GMT -4. The time now is 03:19 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy