I have a file with a list of IPs and a 2nd field: x.x.x.x | 1234
I have an Expect script that requires input:
./runme.exp x.x.x.x 1234
I would like to read the file and use it in the script so I could run the script on multiple servers in a row.
All,
In the past I had a bunch of csv or text files sitting on a web server. My script would loop through all of the folders on the web server and pull out the parts of the files that I wanted.
Recently these files have been moved from the web server to a shared drive that I do not control. I...
As you can see from my recent posts I am new to Expect
I have everything working close to the way I want it now for my data collection. I just a have a couple small issues.
1. The script below adds a non-ascii character to the end of the file name. Is there a better way to do this?
set tdate...
I have redirected the output from my telnet session to a text file.
The text file contains ANSI characters that I do not want, example:
Erase from cursor to end of screen \027[J or \027[0J
[H[J
Is there a way to suppress these characters so that they do not show up in the output file?
Current script:
set tdate [clock format [clock seconds] -format %Y%m%d]
set newName ofcvar_
append newName $tdate
append newName ".txt"
send "expect -f ofcvar.txt > $newName\r"
This gives me a new file like ofcvar_20080919.txt
When I type in the commands above at the expect prompt it works...
Hello,
I am new to TCL and Expect. I wrote an Expect script that pulls the data that I want but I would like to pull it every day and automatically assign the days date as part of the file name.
I tried playing around with exec data but I could not get teh syntax down.
my current code:
#...
I have searched extensively but I have been unable to find a PERL script or sample VBA that will do what I want. I may be using the wrong terminology.
I have a lot of text based reports in the following format:
date 03/06/2008
time 08:00
release 19.0...
I have searched extensively but I have been unable to find a PERL script or module that will do what I want. I may be using the wrong terminology.
I have a lot of text based reports in the following format:
date 03/06/2008
time 08:00
release 19.0...
Hello,
I am trying to automatically collect a file hourly with the following naming convention:
06100512 which is YYMMDDHH
I tried using the following line:
strfmt sGetPCMD "get %02d%02d%02d%02d.PCMD.gz^M" iYear iMonth iDay iHour
This is close but it gives me 4 digit Year instead of 2
Any...
Hello,
I am trying to zip up a file using a date as part of the filename.
My Script
The folder I am zipping is named by the date.
I would like to name the file Test_Date.
strfmt sZipDir "zip -r Test %02d%02d%02d^M" iYear iMonth iDay
I have been experimenting all morning but I have not found...
Hello,
I am new to Aspect and I am trying to figure out how to access a folder with yesterdays date as a name. A new folder is ccreated automatically everyday with the format of 20060515.
I saw this thread (thread448-1027713) that shows how to set the date but I do not know how to reference...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.