Re: Can $1 be set in a script?



On Fri, 31 Mar 2006 01:35:57 -0500, Bill Marcum <bmarcum@xxxxxxxxx>
wrote:

something=${1:-"default string"}

Bill I ran across this exact same construction before in connection
with an ~/.xinitrc script.

Would you please tell me what the syntax means of:
(1:-"default string")

I _guess_ it represents a variable.
What does the colon and minus sign signify?

Larry


--
My real sig is much better.
.



Relevant Pages

  • Create nTDSConnections
    ... I haven't come across a script that will create a AD connection. ... I have used ADSI edit to get the paths I need, but haven't been able to come up with the right syntax. ...
    (microsoft.public.windows.server.scripting)
  • Re: function definition syntax
    ... :> In which case it might as well be a separate script - you don't need a function. ... :>: That's much more reliable than having to remember which syntax ... Always using POSIX ... :> not overlook restoring IFS. ...
    (comp.unix.shell)
  • Re: Books/References new to scripting in AD/2003
    ... my own website has lots of script samples you might find useful: ... test bits of flag attributes like userAccountControl using SQL syntax. ... To restrict the query to an OU, ...
    (microsoft.public.windows.server.scripting)
  • Re: dialup solution (as seconary connection / iptables )
    ... ip-down is launched by pppd only after the PPP link no longer available ... first with MINICOM or is PAP and script not mutualy exclusive? ... do have to "make the connection first with MINICOM." ... If you use the Linux box and route the news IP address to it on each ...
    (comp.os.linux.networking)
  • Re: Books/References new to scripting in AD/2003
    ... Good luck with your scripting - It's a worthwhile pursuit and the time you spend learning to script can easily be re-paid. ... I don't believe there is any way to test bits of flag attributes like userAccountControl using SQL syntax. ... but needs to be enclosed in quotes in a query. ...
    (microsoft.public.windows.server.scripting)