X-Git-Url: https://git.grml.org/?a=blobdiff_plain;f=etc%2Fzsh%2Fcompletion.d%2F_grml-live;h=aff48e8f4f902fc5108bd4474b3ac5eb3eb31664;hb=5730180f96fe169f77d43342e377172e802c7417;hp=9a71298e5e25514064a7fcd6ad0f9924241ee052;hpb=b6256ff5293771a6dcbdbfc5ea303f586d3de3ad;p=grml-live.git diff --git a/etc/zsh/completion.d/_grml-live b/etc/zsh/completion.d/_grml-live index 9a71298..aff48e8 100644 --- a/etc/zsh/completion.d/_grml-live +++ b/etc/zsh/completion.d/_grml-live @@ -4,16 +4,88 @@ # Authors: grml-team (grml.org), (c) Michael Prokop # Bug-Reports: see http://grml.org/bugs/ # License: This file is licensed under the GPL v2. -# Latest change: Mon Sep 17 00:17:42 CEST 2007 [mika] ################################################################################ -arguments=( - '-c:classe(s):(`cd /etc/grml/fai/config/package_config && ls`)' +_grmllive_flavours() { #{{{ + local expl + local -a flavours + + flavours=( + grml grml64 + grml-full grml64-full + grml-small grml64-small + ) + _wanted list expl 'grml flavour(s)' compadd ${expl} -- ${flavours} +} +#}}} +_grmllive_archs() { #{{{ + local expl runningarch + local -a archs + + runningarch="$(dpkg --print-architecture)" + archs=( ${runningarch} ) + [[ ${runningarch} == 'amd64' ]] && archs=( ${archs} 'i386') + _wanted list expl 'target architecture' compadd ${expl} -- ${archs} +} +#}}} +_grmllive_classes() { #{{{ + local expl + local -a already static_classes + + static_classes=( + DEBORPHAN FRESHCLAM + GRMLBASE GRML_FULL GRML_SMALL + LATEX LATEX_CLEANUP LOCALES NO_ONLINE RELEASE REMOVE_DOCS SOURCES XORG ZFS + I386 AMD64 + ) + compset -P '*,' + already=(${(s<,>)IPREFIX}) + _wanted list expl 'classe(s)' compadd -S, -F already -q ${expl} -- \ + /etc/grml/fai/config/class/*(.N:t:r) ${static_classes} +} +#}}} +_grmllive_suites() { #{{{ + local expl + local -a suites + + suites=( + stable testing unstable bookworm sid trixie + ) + _wanted list expl 'Debian suite' compadd ${expl} -- ${suites} +} +#}}} +arguments=( #{{{ + '-a[specifiy architecture to use]:arch(s):_grmllive_archs' + '-A[clean build directories before and after running]' + '-b[build the ISO without updating the chroot via FAI]' + '-B[build the ISO without touching the chroot (skips cleanup)]' + '-c[available grml-live classes]:classe(s):_grmllive_classes' + '-C[configuration file for grml-live]:configuration file:_files' + '-d[use specified date instead of build time as date of release]:date:' + '-D[use specified configuration directory instead of /etc/grml/fai]:directory:_path_files -/' + '-e[extract ISO and squashfs contents from iso_name]:ISO file:' '-F[force execution without prompting for yes/no]' + '-g[grml flavour to use]:grml flavour(s):_grmllive_flavours' '-h[display usage information]' - '-s:Debian suite:(stable testing unstable etch lenny sid)' - '-v[increase verbosity]' + '-i[iso name, ends up in $OUTPUT_DIRECTORY/grml_isos (also see -o)]:ISO name:_files' + '-I[directory which provides files that should become part of the chroot/ISO]:directory to include:_path_files -/' + '-n[skip generation of ISO]' + '-N[bootstrap (build chroot) only, do not create files for ISO]' + '-o[output directory]:output directory:_path_files -/' + '-q[skip mksquashfs]' + '-Q[skip netboot package build]' + '-r[release name]:release name:' + '-s[debian suite to be used for live-system]:Debian suite:_grmllive_suites' + '-S[place of scripts (defaults to /usr/share/grml-live/scripts)]:script directory:_path_files -/' + '-t[template directory]:template directory:_path_files -/' + '-u[update existing chroot instead of rebuilding it from scratch]' + '-U[arrange output to be owned by specified username]' + '-V[increase verbosity]' + '-w[wayback machine, build system using Debian archives from specified date]:date:' + '-z[use ZLIB instead of LZMA/XZ compression]' ) +#}}} + _arguments -s $arguments ## END OF FILE #################################################################