Re: [LIP] bash variable expansion

Raj Mathur <[email protected]>
Newsgroups gmane.user-groups.linux.india.programmers
Message-ID <[email protected]>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

>>>>> "Amit" == Amit Kucheria <[email protected]> writes:

    Amit> Hi, I have a small script below to copy a set of files to a
    Amit> set of machines on the network. I can't figure out how to
    Amit> enable tilde expansion for the first instance of 'fname' in
    Amit> the script even after RTFMing the bash manpage. Any help is
    Amit> appreciated.

If your user ID is in $x, you can tilde-expand it with:

eval echo ~$x

- -- Raju
- -- 
Raj Mathur                [email protected]      http://kandalaya.org/
       GPG: 78D4 FC67 367F 40E2 0DD5  0FEF C968 D0EF CC68 D17F
                      It is the mind that moves
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)
Comment: Processed by Mailcrypt 3.5.6 and Gnu Privacy Guard <http://www.gnupg.org/>

iD8DBQE/uZriyWjQ78xo0X8RAk5YAJ0R5UIv6W1an1RJC3Oywl1+ZIRAnQCgh3Qn
2FZs580pL+U6otJF9h0tF7I=
=TMjT
-----END PGP SIGNATURE-----


-------------------------------------------------------
This SF. Net email is sponsored by: GoToMyPC
GoToMyPC is the fast, easy and secure way to access your computer from
any Web browser or wireless device. Click here to Try it Free!
https://www.gotomypc.com/tr/OSDN/AW/Q4_2003/t/g22lp?Target=mm/g22lp.tmpl
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.