[Pkg-lyx-devel] patch: lyx filename completion for bash

Cengiz Gunay cgunay at emory.edu
Tue Apr 1 03:23:27 UTC 2008


Hi,

I prepared the attached customized bash completion specification for LyX 
by plaguarizing inkscape's specification. Placing the attached file in 
/etc/bash_completion.d/ does the job. I would appreciate it if you can 
include it in the next lyx package update.

Thanks,
Cengiz Gunay
--
cgunay at emory.edu  cengique at users.sf.net (MSN) 	cengique at gmail.com
Lab: +1-404-727-3565	Home/Cell: +1-678-559-8694
http://userwww.service.emory.edu/~cgunay/
IMs: ICQ# 21104923, cengique@{jabber.org,yahoo.com,Skype}
--
-------------- next part --------------
# lyx(1) completion 
# put this file in /etc/bash_completion.d/ 
# Compied inkscape template of allali at univ-mlv.fr
# cengique at users.sf.net

have lyx &&
_lyx()
{
        local cur

        COMPREPLY=()
        cur=${COMP_WORDS[COMP_CWORD]}

        if [[ "$cur" == -* ]]; then
                COMPREPLY=( $( compgen -W '-help -userdir -sysdir \
				-geometry -dbg -x --execute -e --export \
 				-i --import -version' -- $cur ) ) 
        else
                _filedir '@(lyx)'
        fi

}
[ "${have:-}" ] && complete -F _lyx $filenames lyx


More information about the Pkg-lyx-devel mailing list