10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi
The below script used to work fine. Suddenly it's uploading empty file. I am very new to perl. Please help me to find out the problem.
#!/usr/bin/perl
#script: upload.pl
use CGI qw/:standard/;
print header,
start_html('File upload');
print_form();
print_results() if... (2 Replies)
Discussion started by: Anupam_Halder
2 Replies
2. Programming
Hi Guys,
i'm writing a perl script which whenever runs, should empty 3 pre-decided directories as first step and then the script has the logic to parse some other directories and copy the files inside those directories into these 3 directories. I've the logic already developed, just need to... (2 Replies)
Discussion started by: jhamaks
2 Replies
3. Shell Programming and Scripting
Hi, I got problem with queue code how to determined empty and full and problem with while loop
Here is my pseudo code :
Input page Access
Input Pgae Frame
For i =3 to pageframe count by 1
construct queue of size i
set pageFaultCount to 0
while morepages do
page = NextPage... (1 Reply)
Discussion started by: guidely
1 Replies
4. Shell Programming and Scripting
Hi Everyone,
I am looking for neat way to grep a non-empty string that basically contains a hostname, which might be in FWDN form or without the domain, for example:
hostname.internal.domainname.net
The file I am parsing contains blan lines (^$) and also series of "-" which in other places... (2 Replies)
Discussion started by: togr
2 Replies
5. Shell Programming and Scripting
Hi Everyone,
# cat 1
a
b b
cc
1
2
3 3 3
4
55 5
a
b (2 Replies)
Discussion started by: jimmy_y
2 Replies
6. Shell Programming and Scripting
I have a local linux machine in which the files are dumped by a remote ubuntu server. If the process in remote server has any problem then empty files are created in local machine. Is there any way using perl script to check if the empty files are being created and delete them and then run a shell... (2 Replies)
Discussion started by: hussa1n
2 Replies
7. UNIX for Dummies Questions & Answers
Hi All,
I am checking for a empty input file to do some further action , but I am getting exit status 0 in both the cases , for empty and non empty file both.
The value of $? is coming 0 in if part also and else part too.
#!/bin/ksh
if ]; then
echo "data"
# exit 0
echo "$?"
else... (4 Replies)
Discussion started by: mavesum
4 Replies
8. UNIX for Dummies Questions & Answers
Hi,
May I know how to check for empty file in Perl.
Iam missing something, somewhere.
#!/usr/bin/perl
my $open_dir = '/path/';
my $file;
my $ma = "abc_.*.\.psv\$"
opendir(VAR, $open_dir) or die "Can't open $oepn_dir: $!\n";
while( defined ($file = readdir VAR) ) #read all... (1 Reply)
Discussion started by: deepakwins
1 Replies
9. UNIX for Dummies Questions & Answers
hi all:
my solaris FIND does not support
find myFolder -type d -empty
how can i find the empty folders?
thanks! (7 Replies)
Discussion started by: lasse
7 Replies
10. Shell Programming and Scripting
I know this must be really easy, but i can't get it to work
I've got a perl script, with a file.
I want to print an empty line, and the following doesn't seem to work:
print nameoffile "\n"
thanks for your help!! (3 Replies)
Discussion started by: kfad
3 Replies