summaryrefslogtreecommitdiffstats
path: root/bash-completion
Commit message (Collapse)AuthorAgeFilesLines
* bash-completion: (umount) use findmnt, escape a space in pathsKarel Zak2017-11-161-4/+5
| | | | | | | | | | | | | | | # mount /dev/sdc1 /mnt/test/foo\ bar # umount <tab> has to return "/mnt/test/foo\ bar". Changes: * don't use mount | awk output, we have findmnt * force compgen use \n as entries separator Addresses: https://github.com/karelzak/util-linux/issues/539 Signed-off-by: Karel Zak <kzak@redhat.com>
* bash-completion: Exclude /dev/fd from fsck findKevin Locke2017-10-301-1/+2
| | | | | | | | | | | When the bash-completion for fsck runs `find -L /dev/ -type b` it descends into /dev/fd after opening '.' as file descriptor 3. This causes find to search through /dev/fd/3/ which includes everything below the current directory, which can take a very long time. To avoid this, prune /dev/fd in the find expression. Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
* Merge branch 'kill-child-feature' of https://github.com/nh2/util-linuxKarel Zak2017-10-231-0/+1
|\ | | | | | | | | | | | | | | * 'kill-child-feature' of https://github.com/nh2/util-linux: unshare: Allow passing <signame> to --kill-child unshare: Add --kill-child option. signames: Make input char buffers const kill: Extract signal names into signames.h/signames.c
| * unshare: Add --kill-child option.Niklas Hambüchen2017-10-141-0/+1
| | | | | | | | | | | | | | | | | | | | | | This allows to conveniently kill the entire process tree below the forked program, a common problem when scripting tasks that need to reliably fully terminate without leaving reparented subprocesses behind. The example added to the man page shows the most common use. Implemented using prctl(PR_SET_PDEATHSIG, ...).
* | lsmem/chmem: add memory zone awareness to bash-completionAndre Wild2017-10-202-1/+2
|/ | | | | | | | | This patch extends the valid --output values with ZONES for the lsmem bash-completion, and adds the --zone option for the chmem bash-completion. Signed-off-by: Andre Wild <wild@linux.vnet.ibm.com> Signed-off-by: Gerald Schaefer <gerald.schaefer@de.ibm.com>
* bash-completion: update uuidgen, wipefs, tunelp, setpriv, and hwclockSami Kerola2017-09-186-7/+43
| | | | | | | | | | | | | | | | | | | | | uuidgen: Add hash-based UUIDs to bash-completion. These were added in commit c6f1ec68a8b38863efff2a18e30b7272db4fb273. wipefs: Command started to use libsmartcols, and it got some new options. Commit d9921b2a128f17aa9a9a110444d5faa43e1b371c. rename: New option was added in commit fabb90676af89bcb5f429793746f141c0. tunelp: The --trust-irq was removed it being years broken. Commit d52eb4bd9062081c8420b22c029c694f29d036c7. setpriv: Add --ambient-caps option from commit 0c92194eeee9c1fd58580ef852. In same go fix 'bash set -u' issue, that is the same as mentioned commit abbcec4fc9c8d7fb835b4eafd1bc9d82acbf0056. hwclock: For some reason --get has always been missing from this file. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* rfkill: add bash-completion fileSami Kerola2017-08-302-0/+50
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: simplify pid listingSami Kerola2017-08-304-4/+4
| | | | | | | Changing directory in subshell does not effect parent process, so this is better and possibly quicker way to list pids. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: look for look completionsSami Kerola2017-08-051-3/+10
| | | | | | | | | | The look(1) uses positional arguments, where first one is a word from dictionary. It is reasonable to assume most of the time people search from system word lists so propose completions from there. The second argument is a dictionary file, that might invalidate the first input but that only happens to users who have an idea what the want without bash-completion. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: make completions to work when bash set -u is in useSami Kerola2017-07-1514-14/+14
| | | | | | | | | | | | | | | User who want to avoid refering to none-existing variables got earlier the following error. $ set -u $ findmnt --output <tab>bash: OUTPUT: unbound variable Here is short explanation of this setting. $ help set -u Treat unset variables as an error when substituting. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* uuidparse: add bash-completion fileSami Kerola2017-07-152-0/+40
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* partx: add --list-types optionSami Kerola2017-05-031-2/+2
| | | | | | | Use libblkid as the source of truth what partition type names exist, and are supported. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* blkid: add long optionsSami Kerola2017-05-031-18/+52
| | | | | | | | | | | | | This change attempts to make tab completion more reasonable by alloging memorizable option names. That also has positive impact to manual page, in which referrals to other options are now easier to understand. All short options are kept exactly as they were to avoid ABI breakage. The only exception is -f option that getopt(3) recognized, but was not found from anywhere else. The -f has been part of blkid since the initial commit. Commit: 51410fc6deb29cae54a2669aafabae6c49f964fc Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: update text-utilsSami Kerola2017-04-171-0/+5
| | | | | | | | | | hexdump: Add --color option. Commit: 098ab0778f5a46ab4519c8404fd4ba8ec137368b Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: update term-utilsSami Kerola2017-04-173-7/+5Star
| | | | | | | | | | | | | | | | | | | | | scriptreplay: Add --maxdelay option. Commit: 7f1d48363823f7da47ca56f84eb4b2155c5ed36b setterm: Add --resize coption. Commit: 5d795999511adc455d223be8281948796bd7d087 write: List only users who are online and determine tty based on given user name. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: update sys-utilsSami Kerola2017-04-1722-99/+253
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | blkdiscard: Add --step [1] and --zeroout [2] options. Commit [1]: c472a7e35ae40652bdcf66c08a23bd50d48d1884 Commit [2]: 7154cc892688f3c58cbbcdc2055f2635c1d0ef5b chmem: Commit: 30e1ea8ba1984488fdb16506ebafe4dc23280e5a dmesg: Add --time-format. Commit: babf605d2ca969a434f2f14579ddf44252adff4f fallocate: Add --insert-range [1], --collapse-range [2], --zero-range [3], and --posix [4] options. Also make the options to be in same order as usage() output. Commit [1]: b439065634e693dda385a6e5269e1d9258d6d471 Commit [2]: 83cc932d7412cb9d23bf9f06a9a54c8566e1a788 Commit [3]: 1fd4f609ee65be0f376ed28322fc3593026d39e4 Commit [4]: 833f9a7aae713278eec5f85266597482f18c7370 Command [5]: fallocate --help | awk '/--/ {print "\t\t\t\t" $2}' flock: Add --no-fork option. Commit: 703251401cb11ee5d00a6b8f8bd9dc80c160f476 hwclock: Add --udate-drift [1], remove --badyear [2], and use the same argument for --date as in manual page[3]. Commit [1]: f276d71a3ef6a65299deb5e14a188e0a786ecebd Commit [2]: f6374e1fb33d5ca726b72212b787e11fea78c0ca Commit [3]: cc5ec6936ea3c218b3e8c46880659db5ee01329f ldattach: Add --intro-command and --pause. Commit: 8596f6391461bac53f5bab48f8c8b17a7c459f28 losetup: Add --nooverlap [1], --json [2], --noheadings and --raw [3] options, and direct io aka DIO output field [4]. Commit [1]: 9a94b634a343e83bfa2a9d311074e3e520abdddd Commit [2]: 4827093d4b3090389ae0cabb7d8b522cf794ef90 Commit [3]: 9f56106df6b49864ba604f6824f9fad5aeabd17a Commit [4]: faeef4d2e9d5e38bed57846ba903009990f24422 lscpu: Add --json [1] and --physical [2] options. Add DRAWER [3] to output fields. Commit [1]: 19a5510b964c6163e7117913d3de35aba3cd0006 Commit [2]: 0d2b5d2a72bc6619229a4d7456fbb70eda561825 Commit [3]: b3adf6ef6676ca8c10ecdda3e1c92a861df3b885 lsipc: Update output columns (earlier field names were almost completely incorrect). Remove --colon-separate and --print0 [1] options. Add --time-format, --bytes, --numeric-perms [2], and --list [3] options. Commit [1]: 2a7150ac2e57418f471cca0aae259b7bcd0b90db Commit [2]: 9d20ffda794208d26e6b3ed09fbc38d94d0b8fc6 Commit [3]: 2916afa3f510182987f88c17bade5dffb4aaf0b8 lsmem: Commit: cad2d1ac9291112bd9199b36a12335f6770356f3 lsns: Add cgroup --type argument. Commit: 2b8889c44b6752e92bfb982a5eaa2255a129e072 mount: Use /proc and kernel module listing for --type argument list. Some of the items in the lists do not make much sense, but this is still better than a static list provided by package maintainer. mountpoint: Remove fixme item that was left in place when this completion was originally wrote. nsenter: Add --cgroup [1], --setuid, --setgid [2], --preserve-credentials [3] and, --all [4] option. Commit [1]: f9e7b66dbded19d798b883be68b0613749d7b8bb Commit [2]: 6b9e5bf670c70690d44b8ce4055e1997fb0b6496 Commit [3]: e99a6626d6262266f012a20ae69c8e4573ee22fd Commit [4]: 974cc006f122f36e2187cedb9d3e58dc2d24814c rtcwake: Add --auto [1], --adjfile [2], and --list-modes [3] options. Commit [1]: 49ebda9b89fc7360d15ca651b8492633b3bbc1d7 Commit [2]: 3a2f3e82bba616c93d80fd88938b38144e66eee7 Commit [3]: 43a44bfc6da8f4666c5dd6bc03c89713e6c4bd46 setarch: Add --list [1] option. Commit [1]: 5edb0ea6bbd57dd916417737f98c9109dc1ecb5b setsid: Add --wait option. Commit: 0dde19974bcbb07ce977992ab04b7dfa752d99b3 umount: Use /proc and kernel module listing for --type argument list. unshare: Add --cgroup [1], --fork [2], --mount-proc [3], --map-root-user, --setgroups [4], and --propagation [5] options. Commit [1]: f9e7b66dbded19d798b883be68b0613749d7b8bb Commit [2]: 5088ec338fe5dcd7e9a2d8daf7e7fa7dd6f87c27 Commit [3]: 6728ca101e7edc223a8eb99201197831d8daa61f Commit [4]: fbceefded6645de693d576cd988a703a6f60d207 Commit [5]: f0f22e9c6f109f8c1234caa3173368ef43b023eb zramctl: Add new output fields MEM-LIMIT, MEM-USED, and MIGRATED. Commit: bffc9174b89d8d9fefe7a77b9350ab8f0dbef54f Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: update schedutilsSami Kerola2017-04-171-1/+13
| | | | | | | | | | ionice: Add --pgid and --uid options. Commit: bd2ff3d2d952d75a6707846831623455647a9a8d Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: update misc-utilsSami Kerola2017-04-178-29/+85
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | fincore: Add RES column to --output completions. Commit: e4e8b57be2b63fed82647e4d5efd0e0eaf36b19e findfs: Commit: 940817b736bceccca9be6b9b73e4dd7da0d89142 logger: Add --socket-errors [1] and --tcp [2] options. Commit [1]: d77dc29e6e18d39b1845282e8039ac7117f3bd1c Commit [2]: 68265d070d3041d16ab074ba25c610d6ef6c842e lsblk: Add HOTPLUG [1], SERIAL [2], and SUBSYSTEMS [3] output fields. Add --json [4], --output-all [5], and --paths [6] options. Commit [1]: 483987c275e461f4118a89d3be013698845d702b Commit [2]: 460c7afb79075bd5b39e7d4bc153aa41c939bab3 Commit [3]: 7f14ee1b551e839a4ae081c8d2b7633ca40a5823 Commit [4]: 4a102a4871fdb415f4de5af9ffb7a2fb8926b5d1 Commit [5]: 1b4d2a4a4aa7df52033d293f26cd4fa79f95578d Commit [6]: c7e76cd145b0c40e1d346203f3222f5937146939 lslocks: Add --noinaccessible option. Remove file argument completion, this command does not use that sort of command line input. Commit: f29bc6e1cc4ed9f76bded543c6ab393f674ec3ed mcookie: Add --max-size option. Commit: f7bac5731bf559216aa2f0e8be1d7f477e7cf41a wipefs: Add --backup option. Commit: 7e658c15a2c1fc5092a790afbe7d9d395d04b098 Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: update login-utilsSami Kerola2017-04-171-10/+24
| | | | | | | | | last: Broken since first commit. Commit: 41e5a92cf1cd8950df8b02fdd2ea8be571dbab02 Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: update disk-utilsSami Kerola2017-04-176-12/+119
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | fdformat: Add --from, --to, and --repair options. Commit: e0402441a143533d33d3c450471b2cd655407d77 fdisk: Add --output [1], --bytes [2], --wipe [3], --wipe-partition [4], and remove --geom- from from --cylinders, --heads, --sector options [5]. Commit [1]: fff8ad5882308825a131c645e4d28bcaef943351 Commit [2]: 354f8cc8cf06de44656fb83705c57062d04d1565 Commit [3]: cb9a4b0033eca429689a403be2a192fe2842f2e9 Commit [4]: ba465623d84b9e330f248a477d078b5f280b7943 Commit [5]: 4b4e391a28b4dfeb69781c20190bffe8622d1907 fsck.cramfs: Broken since first commit. Commit: bf60993cf2442f67bd47bcfcf6bd49c7392c2ba1 mkswap: Provide random uuid when completing --uuid argument. partx: Add --sector-size option. Fix also list of known partition types to match with libblkid blkid_idinfo names. The fix is also applied to manual page. Commit: f8a4a0d4f2fd569252029bd004e24ee433b43fe8 Reference: git grep -A 4 blkid_idinfo libblkid/src/partitions | grep name sfdisk: Add --reoder, --delete, --mode-dataa, -no-tell-kernel, --wipe, and --wipe-partitions options. In same go fix some option argument completions. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tailf: remove deprecated utilitySami Kerola2017-04-022-31/+0Star
| | | | | | | | March 2017 is gone, it is time to remove this utility as scheduled in earlier commit, and promised in manual page. Reference: 3f8478a71ccde6883d4c81b7e65561a106653b28 Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: update fincore to have latest optionsSami Kerola2017-03-241-2/+23
| | | | | | Also include --output smartcols fields. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: add a function for fincore commandMasatake YAMATO2017-03-232-0/+28
| | | | Signed-off-by: Masatake YAMATO <yamato@redhat.com>
* blkzone: add count option to bash-completionKarel Zak2017-02-241-1/+5
| | | | | | and fix typo in man page Signed-off-by: Karel Zak <kzak@redhat.com>
* blkreport, blkreset: remove in favour of blkzoneKarel Zak2017-02-231-34/+0Star
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* blkzone: add bash-completionKarel Zak2017-02-232-0/+51
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* rename: add --no-act to bash-completionKarel Zak2017-02-151-1/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* bash-completion: add blkreset and blkreport completionSami Kerola2017-02-131-0/+34
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* hwclock: remove --compare optionSami Kerola2017-02-051-1/+0Star
| | | | | | | | | | | Compare functionality was printing nonsense values. There is no knowledge of anyone using this broken functionality. Instead of deprecating the code for months, and removing it after few release, it is removed immediately. Needless to say this is unusual removal. Reference: http://marc.info/?l=util-linux-ng&m=148396210506652&w=2 Signed-off-by: Karel Zak <kzak@redhat.com> Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* findmnt: add --tree to allow to enable tree output for --mtabKarel Zak2016-12-081-0/+1
| | | | | | | | | | | | The --mtab output is merge from kernel and utab on all modern systems (without classic /etc/mtab). It means we have all necessary information to generate tree output. For the backward compatibility --mtab is the list by default, the new option --tree allows to override the default and enable tree always when the table contains child-parent relations. Signed-off-by: Karel Zak <kzak@redhat.com>
* wall: check -g GIDKarel Zak2016-12-021-1/+1
| | | | | | Based on comments from Sami Kerola. Signed-off-by: Karel Zak <kzak@redhat.com>
* wall: add --group optionJim Patterson2016-12-021-0/+4
| | | | | | | | | | | | | | | | The wall command on AIX supports a "-g" option to limit the message to a group of users by gid. Add compatibility to the Linux version. Thanks to Sami Kerola <kerolasa@iki.fi> for an initial skeleton implementation. [kzak@redhat.com: - rename max to ngroups - add free_group_workspace() - some cosmetic changes] Reference: http://www.ibm.com/support/knowledgecenter/ssw_aix_61/com.ibm.aix.cmds6/wall.htm Signed-off-by: Jim Patterson <jimp@wegrok.net> Signed-off-by: Karel Zak <kzak@redhat.com>
* Fix: list all block device from /dev and all symbolic links to block devicesRichard Yann2016-10-041-1/+1
| | | | Before fix "fsck -y /d<tab>" will never show LVM VG from multipath or mapped devices
* bash-completion: update chrt completionSami Kerola2016-04-041-13/+27
| | | | | | | | | | | | Add couple missing options, and make the completion overall work better. That said completion is still incomplete, pardon the pun. After user has specified policy then giving a hint what priority needs to be specified is theoretically possible, but such hint is not given. There does not seem to be easy way to know when user wants stops specifying options and move to defining priority in: chrt [options] [prio] [command|pid]. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* build-sys: install missing bash completionsRuediger Meier2016-03-171-0/+5
| | | | | | | We haven't installed these files since three years. Hopefully they will work. Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
* bash-completion: lsns: add missing completion fileSami Kerola2016-03-142-0/+59
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: lslogins: add missing completion fileSami Kerola2016-03-142-0/+79
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: ipcmk: add missing completion fileSami Kerola2016-03-142-0/+30
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: fsck.cramfs, isosize: find files an argumentSami Kerola2016-03-142-4/+18
| | | | | | | Earlier completion suggested only options for the command, this changes options to be proposed when first character of an argument is dash. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: fstrim: use mountpoint, not deviceAndreas Henriksson2015-11-131-1/+1
| | | | | | | | | fstrim takes mountpoint as argument but the bash completion was completing it to a device node. Addresses: http://bugs.debian.org/804833 Reported-by: Ritesh Raj Sarraf <rrs@debian.org> Signed-off-by: Andreas Henriksson <andreas@fatal.se>
* bash-completion: add cal --spanKarel Zak2015-11-051-0/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* bash-completion: curly brace missed for findmntAlexander Kuleshov2015-10-021-1/+1
| | | | | | | | | | | | | This patch provides fix for bash-completion/fndmt script. There is curly brace missed in the completion generation for the -M/--mountpoint option. In other way we will get following messages: bash: /etc/bash_completion.d/findmnt: line 91: unexpected EOF while looking for matching `)' bash: /etc/bash_completion.d/findmnt: line 141: syntax error: unexpected end of file Signed-off-by: Alexander Kuleshov <kuleshovmail@gmail.com>
* bash-completion: update few options changed since v2.26Sami Kerola2015-08-035-40/+63
| | | | | | | | Attempt to find and update all changes to command line options that has not been reflected in bash-completion files in between versions v2.26 to v2.27-rc1. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* fsck.minix: introduce long options to the commandSami Kerola2015-07-301-6/+6
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* mkfs.minix: introduce long options to the commandSami Kerola2015-07-301-9/+7Star
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* sfdisk: add --list-freeKarel Zak2015-07-281-0/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* lsipc: new command to list IPC facilitiesKarel Zak2015-07-202-0/+68
| | | | | | Co-Author: Karel Zak <kzak@redhat.com> Signed-off-by: Karel Zak <kzak@redhat.com> Signed-off-by: Ondrej Oprala <ooprala@redhat.com>
* bash-completion: cal: add --twelve and --color optionsSami Kerola2015-07-151-7/+14
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* rtcwake: add --list-modesSami Kerola2015-06-291-1/+1
| | | | | | | | | | | Commit ece44f19f423408f576f348fed2845c876d72c6e missed freeze mode, which to a simple patch adding the missing argument but Karel pointed out it would be better to make the rtcwake to tell what arguments are supported so that possible changes end up to be automatically correct in bash completion. Proposed-by: Karel Zak <kzak@redhat.com> Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* rtcwake: add human readable --date timestamp formatSami Kerola2015-06-291-1/+6
| | | | | Reviewed-by: Benno Schulenberg <bensberg@justemail.net> Signed-off-by: Sami Kerola <kerolasa@iki.fi>