GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- meaning of $@
Operating System - HP-UX
1847227
Members
3003
Online
110263
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-15-2008 11:23 AM
4 REPLIES 4
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-15-2008 11:27 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-15-2008 11:33 AM
02-15-2008 11:33 AM
Re: meaning of $@
In what context are you asking? They can take different meaning form shells and regular expressions, to vi, to senmail rules etc.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-15-2008 11:38 AM
02-15-2008 11:38 AM
Re: meaning of $@
Inside a korn shell it means.....
gimme all the supplied command line args
a script that does this:
echo $@
Will do this when run with args
./test.ksh arg1 arg2 arg3
arg1 arg2 arg3
gimme all the supplied command line args
a script that does this:
echo $@
Will do this when run with args
./test.ksh arg1 arg2 arg3
arg1 arg2 arg3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-15-2008 01:44 PM
02-15-2008 01:44 PM
Re: meaning of $@
Hi,
I want to remember the special meaning of
"$@" (in double quotes), which saves spaces contained in arguments.
Continuing and modifying Tim's example with
cat test.ksh
#!/usr/bin/ksh
for i in "$@"
do print "arg='$i'"
done
and a command line of
./test.ksh 'arg1 arg2' arg3
will lead to an output
arg='arg1 arg2'
arg='arg3'
mfG Peter
I want to remember the special meaning of
"$@" (in double quotes), which saves spaces contained in arguments.
Continuing and modifying Tim's example with
cat test.ksh
#!/usr/bin/ksh
for i in "$@"
do print "arg='$i'"
done
and a command line of
./test.ksh 'arg1 arg2' arg3
will lead to an output
arg='arg1 arg2'
arg='arg3'
mfG Peter
The Universe is a pretty big place,
it's bigger than anything anyone has ever dreamed of before.
So if it's just us, seems like an awful waste of space, right?
Jodie Foster in "Contact"
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2026 Hewlett Packard Enterprise Development LP