UNIX Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsOperating SystemsUNIX Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old October 23rd, 2005, 12:20 PM
robbrown robbrown is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2002
Posts: 353 robbrown User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 20 h 32 m 55 sec
Reputation Power: 7
Arrow alias with quotation marks

I'm trying to create an alias to a command that requires quotes. How can I tell the system to ignore a set of quotation marks?

Eg:

alias-"command -j "new run now" -x"

It's the quotes in the middle that are giving me a problem.

Any help is greatly appreciated.

Reply With Quote
  #2  
Old October 24th, 2005, 07:17 AM
Oraly Oraly is offline
Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2001
Location: Stavanger
Posts: 83 Oraly User rank is Lance Corporal (50 - 100 Reputation Level)Oraly User rank is Lance Corporal (50 - 100 Reputation Level)Oraly User rank is Lance Corporal (50 - 100 Reputation Level) 
Time spent in forums: 20 h 13 m 24 sec
Reputation Power: 8
Well I don't know if that is possible in the way you're trying to do it, but you could always write a script to do the job.
Using bash, for example, you can build the command the way you want it to be, and then you call the script when you need to run the command.

I'm not sure of this next part, since I haven't tried it myself, but could it be that the following works:
Code:
alias-' "command -j "new run now" -x" '

... or something like that

Reply With Quote
  #3  
Old October 24th, 2005, 10:22 AM
robbrown robbrown is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2002
Posts: 353 robbrown User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 20 h 32 m 55 sec
Reputation Power: 7
Thanks for the reply! The alias thing didn't work, but your sugguestion for a script is a great idea! Thanks.

Reply With Quote
Reply

Viewing: Dev Shed ForumsOperating SystemsUNIX Help > alias with quotation marks


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway