Search Results

Search: Posts Made By: script2010
13,467
Posted By script2010
I need to the diff in perl. This wouldn't work. ...
I need to the diff in perl. This wouldn't work.

I already have a file.txt with the list of filename. I open this file and for each file, I need to do the diff.

This is my code so far..


...
13,467
Posted By script2010
yes, they will have the same file names. ...
yes, they will have the same file names.

(There are a few files that are present in folderA but not in folderB. In that case I need to copy them as is to folderB)
13,467
Posted By script2010
PERL Scripting: Diff 2 files and save output to file3
Hi,

I need to create a script to compare 2 files and store the output in a 3rd file.
This is how I do manually, but since I need to do this for about 150 files every week, I am trying to...
3,442
Posted By script2010
Ha :) Thank u so much. A set of small...
Ha :)

Thank u so much.

A set of small quotes killed my day !
3,442
Posted By script2010
Thanks, I am trying to save this output to...
Thanks,

I am trying to save this output to a variable, but it throw me an error:


#!/bin/sh
cdate=`date +%Y%m%d_%I%M%p`
$pdate=date -d "3 days ago"
echo $cdate
echo $pdate


...
3,442
Posted By script2010
Thanks for the response. I am on Ubuntu...
Thanks for the response.

I am on Ubuntu working on bash.

date && date -v -3d

does d in -3d mean day ? I need say -4hours.
84,735
Posted By script2010
Thanks everyone, I got it to work !
Thanks everyone, I got it to work !
11,137
Posted By script2010
Thanks will try this.
Thanks will try this.
3,442
Posted By script2010
How to get date-3 value in sh.
Hi,

I am doing a shell script and I need the date (tdate-3) value, example if my tdate is,

tdate=`date +%Y%m%d_%I%M%p` (variable 1 could be from few hours old, not present date at the time I...
84,735
Posted By script2010
Truncate string variable
Hi,

I want to truncate a string variable, returned in the script. In perl I used the below and it worked.

BRNo=BR12345
$BR = substr($BRNo, 2, 7)

How can I do it in sh.

Thanks !
11,137
Posted By script2010
After I find the string, I need to remove 'BR'...
After I find the string, I need to remove 'BR' from it, and just store the numbers following 'BR'

The following worked for .pl script. How can I change it to work in shell script ?

$BR =...
11,137
Posted By script2010
Thank you so much. it worked !
Thank you so much. it worked !
11,137
Posted By script2010
Parse file and copy value to variable in sh script.
Hi,

I need to parse a simple text file like below and store the word that starts with BR* to a variable say $BRno. I need to do this in sh script.

NOTE: the length of the numbers following BR...
4,272
Posted By script2010
Parse text file in shell & store to variable
Hi,

I need to parse a simple text file like below and store the word that starts with BR* to a variable say $BRno. I need to do this in sh script.

NOTE: the length of the numbers following BR...
Showing results 1 to 14 of 14

 
All times are GMT -4. The time now is 03:28 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy