-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Am 14.11.2014 um 02:04 schrieb David Adam: > I think the `commandline` builtin is what you want. > > ``` > -a '(drush --early=includes/complete.inc (commandline -cpo))' ```
This is amazing, exavtly what I was looking for. In the end, my specific requirement needed some more tweaks (I guess they are drush related) and the working solution now looks like this: ``` # Drush autocompletion function __complete_drush drush --early=includes/complete.inc (commandline -cpo) (commandline - -t)|cut -d " " -f 1 end complete -x -c drush -d "Drush" -a "(__complete_drush)" ``` I need the "commandline" command twice as the first one forgets the last token in the line. And I also need to pipe the result through "cut" as the result from drush separates the matches with "\n " which confuses fish completion. However, this is now working and I'm super happy. Thanks David!! Jürgen -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQEcBAEBAgAGBQJUZfdyAAoJEGMwkysX8CIna6EIAKPpS8HE+waRcVI/PB+3BoQC NffA0vCIubKKb6IRTzWtNzEKCXENGegXUs5GAQRRWMzT8l11gFqZ1AJjhRfsFquv Ziyg2qdW63MTui1RX72cfjuajr6fBvYLMrZY24wLv6NKowwE+8lpeA8bDnQ/se0R Ox266rYImZvdF6dbMiNrEt3hEoGYEfaRmDod86e4tnAqaaC3fkbDFPW92NyMppyh 5kIXn6r75o7rEdN4XhBASHVfRfC7SgiGuGi04dpPyuT7HGXVV8SE+MGbn6a+GoMs cXZ6ft/LsGYp1j9uhFhmQ3qALGP3kb7vF85Qan8Iccwg7xz5a0fLdVDz25I+OgA= =msug -----END PGP SIGNATURE----- ------------------------------------------------------------------------------ Comprehensive Server Monitoring with Site24x7. Monitor 10 servers for $9/Month. Get alerted through email, SMS, voice calls or mobile push notifications. Take corrective actions from your mobile device. http://pubads.g.doubleclick.net/gampad/clk?id=154624111&iu=/4140/ostg.clktrk _______________________________________________ Fish-users mailing list Fish-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/fish-users