07-24-2008
how to find the path of a file when it is passed as ....filename(parameter) to script
hi unix guru's..................
question is posted in the #3 permalink shown below.
Last edited by yahoo!; 07-24-2008 at 08:19 AM..
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I am passing a file name as a parameter to shell script
the parameter is getfile.txt.gpg
how do i process this parameter to get name like getfile.txt only and eleminate the .gpg text??
Thanks in advance (2 Replies)
Discussion started by: rudoraj
2 Replies
2. UNIX for Dummies Questions & Answers
Hi,
I will pass 3 parameters for a script.I have to check the file name and create a new file name with time stamp.
the parameters which i'm passing are
/dir/stg/filename.txt
/dir/path/head.txt
/dir/path/tail.txt
Now i have to check filename like :
if it is a.txt i have to create... (2 Replies)
Discussion started by: ammu
2 Replies
3. Shell Programming and Scripting
Hi,
I have a requirement to write a script file(script1.sh) to read the file from the folder say /usr1/profiles/active and pass the file name as a parameter to another script file say (script2.sh) which would subsitute this parameter.
The script2.sh will have a line like the one below
... (1 Reply)
Discussion started by: ravisg
1 Replies
4. Shell Programming and Scripting
Hi,
I am executing a shell script which takes a string as a parameter.
The scipt should validate the string and create the directoy with the name of specfied string.
The following is the specified command and its parameter.
test.sh "abc abc"
The shell script is not able to identify... (4 Replies)
Discussion started by: raghu.amilineni
4 Replies
5. Shell Programming and Scripting
i got a file called Pass1, and then i need to passed a number to my script with the '-p pass_mark' option.
Example type
Pass1 -p 18
to pass 18 to my script for comparing things, so how can i do it? (7 Replies)
Discussion started by: mingming88
7 Replies
6. Shell Programming and Scripting
Hello Everyone,
I have been trying to complete a shell script where, I need to increment the date depending on the file (depending on the date) availability on the remote server.
i.e.
Basically, I will be passing a counter (like parameter 1 or 2 or 3 or 4).
First I will check for the... (1 Reply)
Discussion started by: filter
1 Replies
7. Shell Programming and Scripting
Hi
I am looking for a unix command or a small shell script which can takes one parameter and then searches for the passed in the parameter in any or all files under say /home/dev/
Can anyone please help me on this? (3 Replies)
Discussion started by: pankaj80
3 Replies
8. Shell Programming and Scripting
I want to make a script which takes the number of argument, add those argument and gives output to the user, but I am not getting through...
Script that i am using is below :
#!/bin/bash
sum=0
for i in $@
do
sum=$sum+$1
echo $sum
shift
done
I am executing the script as... (3 Replies)
Discussion started by: mukulverma2408
3 Replies
9. Shell Programming and Scripting
Hi,
I have the following files.
->cat scr.sh
export TMP_DIR=/home/user/folder1
export TMP_DIR_2=/home/user/folder2
while read line
do
cat "$line"
done<file_list.dat
------------------------
-> cat file_list.dat
$TMP_DIR/file1.txt
$TMP_DIR_2/file2.txt
---------------------------
-> cat... (6 Replies)
Discussion started by: barath
6 Replies
10. Shell Programming and Scripting
Example:
I have server name A with an IP : 125.252.235.455
I have an username /password to login into this server under SSH connection
In this server i have a path /apps/user/filename(Big.txt)
Everyday we used to get the filename as Big.txt.
I want a shell script to monitor this path... (4 Replies)
Discussion started by: ChandruBala73
4 Replies
LEARN ABOUT DEBIAN
xml::feed::entry
XML::Feed::Entry(3pm) User Contributed Perl Documentation XML::Feed::Entry(3pm)
NAME
XML::Feed::Entry - Entry/item in a syndication feed
SYNOPSIS
## $feed is an XML::Feed object.
for my $entry ($feed->entries) {
print $entry->title, "
", $entry->summary, "
";
}
DESCRIPTION
XML::Feed::Entry represents an entry/item in an XML::Feed syndication feed.
USAGE
XML::Feed::Entry->new($format)
Creates a new XML::Feed::Entry object in the format $format, which should be either RSS or Atom.
$entry->convert($format)
Converts the XML::Feed::Entry object into the $format format, and returns the new object.
$entry->title([ $title ])
The title of the entry.
$entry->base([ $base ])
The url base of the entry.
$entry->link([ $uri ])
The permalink of the entry, in most cases, except in cases where it points instead to an offsite URI referenced in the entry.
$entry->content([ $content ])
An XML::Feed::Content object representing the full entry body, or as much as is available in the feed.
In RSS feeds, this method will look first for <http://purl.org/rss/1.0/modules/content/#encoded> and <http://www.w3.org/1999/xhtml#body>
elements, then fall back to a <description> element.
$entry->summary([ $summary ])
An XML::Feed::Content object representing a short summary of the entry. Possibly.
Since RSS feeds do not have the idea of a summary separate from the entry body, this may not always be what you want. If the entry contains
both a <description> element and another element typically used for the full content of the entry--either http://www.w3.org/1999/xhtml/body
or <http://purl.org/rss/1.0/modules/content/#encoded>--we treat that as the summary. Otherwise, we assume that there isn't a summary, and
return an XML::Feed::Content object with an empty string in the body.
$entry->category([ $category ])
The category in which the entry was posted.
Returns a list of categories if called in array context or the first category if called in scalar context.
WARNING It's possible this API might change to have an add_category instead.
$entry->tags([ $tag ])
A synonym (alias) for category;
$entry->author([ $author ])
The name or email address of the person who posted the entry.
$entry->id([ $id ])
The unique ID of the entry.
$entry->issued([ $issued ])
A DateTime object representing the date and time at which the entry was posted.
If present, $issued should be a DateTime object.
$entry->modified([ $modified ])
A DateTime object representing the last-modified date of the entry.
If present, $modified should be a DateTime object.
$entry->wrap
Take an entry in its native format and turn it into an XML::Feed::Entry object.
$entry->unwrap
Take an XML::Feed::Entry object and turn it into its native format.
AUTHOR & COPYRIGHT
Please see the XML::Feed manpage for author, copyright, and license information.
perl v5.14.2 2012-03-21 XML::Feed::Entry(3pm)