www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.announce - bash completion for dmd and rdmd

reply Lutger <lutger.blijdestijn gmail.com> writes:
It's ugly but it seems to work: http://dl.dropbox.com/u/6777848/d-completion.sh

Put it in /etc/bash_completion.d/ or (preferably) invoke it from ~/.bashrc or 
~/.bash_profile:

. d-completion.sh

It will enable autocomplete for dmd and rdmd in bash. You may need to install 
the bash-completion package of your distro.
Sep 12 2010
next sibling parent reply Andrei Alexandrescu <SeeWebsiteForEmail erdani.org> writes:
On 9/12/10 10:48 CDT, Lutger wrote:
 It's ugly but it seems to work: http://dl.dropbox.com/u/6777848/d-completion.sh

 Put it in /etc/bash_completion.d/ or (preferably) invoke it from ~/.bashrc or
 ~/.bash_profile:

 .. d-completion.sh

 It will enable autocomplete for dmd and rdmd in bash. You may need to install
 the bash-completion package of your distro.
Cool! This should be on D's website. Any zsh completion experts to provide something similar for zsh? Andrei
Sep 12 2010
next sibling parent "Masahiro Nakagawa" <repeatedly gmail.com> writes:
On Mon, 13 Sep 2010 01:54:16 +0900, Andrei Alexandrescu  
<SeeWebsiteForEmail erdani.org> wrote:

 On 9/12/10 10:48 CDT, Lutger wrote:
 It's ugly but it seems to work:  
 http://dl.dropbox.com/u/6777848/d-completion.sh

 Put it in /etc/bash_completion.d/ or (preferably) invoke it from  
 ~/.bashrc or
 ~/.bash_profile:

 .. d-completion.sh

 It will enable autocomplete for dmd and rdmd in bash. You may need to  
 install
 the bash-completion package of your distro.
Cool! This should be on D's website. Any zsh completion experts to provide something similar for zsh?
I'm not a zsh completion experts, but I use following script. http://dl.dropbox.com/u/374829/_dmd
Sep 12 2010
prev sibling parent Lutger <lutger.blijdestijn gmail.com> writes:
Andrei Alexandrescu wrote:

 On 9/12/10 10:48 CDT, Lutger wrote:
 It's ugly but it seems to work:
 http://dl.dropbox.com/u/6777848/d-completion.sh

 Put it in /etc/bash_completion.d/ or (preferably) invoke it from ~/.bashrc or
 ~/.bash_profile:

 .. d-completion.sh

 It will enable autocomplete for dmd and rdmd in bash. You may need to install
 the bash-completion package of your distro.
Cool! This should be on D's website. Any zsh completion experts to provide something similar for zsh? Andrei
Thanks. As per suggestion of Russel Winder I created a github account: http://github.com/Lutger/d_utils I've added completion for the linker. The script should be cleaned up though before putting it on the D website. I'll try to do it but I don't know bash very well, so it takes some time.
Sep 12 2010
prev sibling next sibling parent "Nick Sabalausky" <a a.a> writes:
"Lutger" <lutger.blijdestijn gmail.com> wrote in message 
news:i6isov$v0h$1 digitalmars.com...
 It's ugly but it seems to work: 
 http://dl.dropbox.com/u/6777848/d-completion.sh

 Put it in /etc/bash_completion.d/ or (preferably) invoke it from ~/.bashrc 
 or
 ~/.bash_profile:

 . d-completion.sh

 It will enable autocomplete for dmd and rdmd in bash. You may need to 
 install
 the bash-completion package of your distro.
Ahh, cool! I'd often wondered how autocomplete in bash often seems to work even for non-files. (Yea, not exactly a Unix-guru here ;) )
Sep 12 2010
prev sibling next sibling parent Russel Winder <russel russel.org.uk> writes:
On Sun, 2010-09-12 at 17:48 +0200, Lutger wrote:
 It's ugly but it seems to work: http://dl.dropbox.com/u/6777848/d-complet=
ion.sh
=20
 Put it in /etc/bash_completion.d/ or (preferably) invoke it from ~/.bashr=
c or=20
 ~/.bash_profile:
=20
 . d-completion.sh
=20
 It will enable autocomplete for dmd and rdmd in bash. You may need to ins=
tall=20
 the bash-completion package of your distro.
Any chance of putting it into DVCS so that it can be evolved? Bazaar/Launchpad, Mercurial/BitBucket, Git/GitHub are good options. --=20 Russel. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D Dr Russel Winder t: +44 20 7585 2200 voip: sip:russel.winder ekiga.n= et 41 Buckmaster Road m: +44 7770 465 077 xmpp: russel russel.org.uk London SW11 1EN, UK w: www.russel.org.uk skype: russel_winder
Sep 12 2010
prev sibling parent reply Jordi Sayol <g.sayol yahoo.es> writes:
Al 12/09/10 17:48, En/na Lutger ha escrit:
 It's ugly but it seems to work: http://dl.dropbox.com/u/6777848/d-completion.sh

 Put it in /etc/bash_completion.d/ or (preferably) invoke it from ~/.bashrc or
 ~/.bash_profile:

 . d-completion.sh

 It will enable autocomplete for dmd and rdmd in bash. You may need to install
 the bash-completion package of your distro.
Can I add it on the next deb/rpm packages? -- Jordi Sayol
Sep 14 2010
parent Lutger <lutger.blijdestijn gmail.com> writes:
Jordi Sayol wrote:

 Al 12/09/10 17:48, En/na Lutger ha escrit:
 It's ugly but it seems to work:
 http://dl.dropbox.com/u/6777848/d-completion.sh

 Put it in /etc/bash_completion.d/ or (preferably) invoke it from ~/.bashrc or
 ~/.bash_profile:

 . d-completion.sh

 It will enable autocomplete for dmd and rdmd in bash. You may need to install
 the bash-completion package of your distro.
Can I add it on the next deb/rpm packages?
Of course! But please use this version: http://github.com/Lutger/d_utils I'll be happy to know if there are any errors, it's mostly taken from existing completion scripts. I don't think such a small script needs a license but I'll put one in if needed.
Sep 14 2010