Options for control of output in Terminal?
I'm working on a multithreaded perl script that will have a group of threads uploading files via FTP. I'd like to have each thread display status information in the Terminal window, e.g.: Terminal- Thr1 16:12:07: Uploading 'mysamplefile' (890.0 KB) to 'myhost.com' ## Thr2 16:10:07: Uploading 'myBIGsamplefile' (99.1 MB) to 'myhost.com' # Thr3 16:05:08: Uploaded 'lastfile' (5.1 MB) to 'ftpserver.com' Thr4 16:13:06: Uploading littlefile' (44.8 KB) to 'anotherhost.com' ## - The # symbols above would be the hash output from Net::FTP as it uploads ... Ideally, I'd like to have the window have a fixed display (no scrolling) and always output the information from a specific thread in a specific position. In other words, Thread 1 gets the first 2 lines, Thread 2 gets lines 3 and 4, etc. The script right now is not threaded, and using the hash output from Net::FTP works great - divide filesize by 100 and set that to your hash value to get a great text-based progress bar. How could I put information into a static display like this? And could I still use the Net::FTP progress bar? Suggestions appreciated. Thanks, Dan
Re: Getting DBD-Sybase to work
I got DBD-Sybase working OK, but did need to set additional environment variables - both when compiling and when running the script. Here is the block I have at the beginning of my Perl script that seems to work just fine: BEGIN { $ENV{SYBASE}= '/Applications/Sybase/System'; $ENV{SYBASE_OCS}= 'OCS-12_5'; $ENV{SYBASE_ASE}= 'ASE-12_5'; $ENV{SYBASE_SYSAM} = 'SYSAM-1_0'; } ISTR that I set these prior to compiling from the command line and it compiled OK. Good luck! Dan At 10:59 PM -0500 1/14/04, gohaku wrote: Hi everyone, I just installed Sybase ASE 12.5.1 on OS X v10.3.2 and am trying to Install the DBD-Sybase-1.02 module. When I tried to install said module, I got back the following: Please set SYBASE in CONFIG, or set the $SYBASE environment variable at Makefile.PL line 93, IN line 44. I then tried: setenv SYBASE /Applications/Sybase/System/ASE-12_5/ perl Makefile.PL and got back the following: Can't find the lib or include directories under /Applications/Sybase/System/ASE-12_5/! at Makefile.PL line 102, IN line 44. I also read the article: Sybase for Mac OS X (http://www.oreillynet.com/pub/wlg/1693) to see if that could help me but I couldn't even login as Superuser. Does anybody know what I'm doing wrong? Thanks in advance. -Gohaku
Re: ***regular expression***
I'm guessing you want 'string' to be what follows 'idlink'? If so, this ought to work: $url =~ s/a href.*?(.*?)\/a/idlink$1/i; Change the 'i' at the end to 'gi' (for global, insensitive) to have it process a string with multiple URLs. HTH, Dan Can someone help me about a regular ? In which way i can substitute a href=$urlstring/a with idlink$val1. Thanks Paolo