<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/util-linux.git/bash-completion/fsck, branch master</title>
<subtitle>git.kernel.org: pub/scm/utils/util-linux/util-linux.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/util-linux.git/'/>
<entry>
<title>bash-completion: Add fallback for symlinks/images</title>
<updated>2019-09-19T14:16:32+00:00</updated>
<author>
<name>Kevin Locke</name>
<email>kevin@kevinlocke.name</email>
</author>
<published>2019-09-19T13:40:13+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/util-linux.git/commit/?id=6ead91ce1e8431bec5b6f10c37b54a82f0be078a'/>
<id>6ead91ce1e8431bec5b6f10c37b54a82f0be078a</id>
<content type='text'>
For commands which support operating on files (i.e. disk images), it is
desirable for bash-completion to complete matching file names.  It is
also desirable to complete on block device symlinks (e.g. under
/dev/disk).  To complete common use cases, often on canonical device
names, continue to try completion using canonical device names, then
fall back to matching any file incrementally as Bash does by default.[1]

[1]: https://github.com/karelzak/util-linux/issues/842#issuecomment-523450243

Signed-off-by: Kevin Locke &lt;kevin@kevinlocke.name&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
For commands which support operating on files (i.e. disk images), it is
desirable for bash-completion to complete matching file names.  It is
also desirable to complete on block device symlinks (e.g. under
/dev/disk).  To complete common use cases, often on canonical device
names, continue to try completion using canonical device names, then
fall back to matching any file incrementally as Bash does by default.[1]

[1]: https://github.com/karelzak/util-linux/issues/842#issuecomment-523450243

Signed-off-by: Kevin Locke &lt;kevin@kevinlocke.name&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>bash-completion: Standardize fsck/mkfs file/device</title>
<updated>2019-09-19T13:27:31+00:00</updated>
<author>
<name>Kevin Locke</name>
<email>kevin@kevinlocke.name</email>
</author>
<published>2019-09-19T13:27:31+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/util-linux.git/commit/?id=559888c873a196c790137bbeee678dc5212c4430'/>
<id>559888c873a196c790137bbeee678dc5212c4430</id>
<content type='text'>
Some of the fsck and mkfs commands complete differently than the others,
and differently than the desired behavior.[1]  Standardize on completing
with $(lsblk -pnro name):

* fsck: Don't complete completes on all block devices and device links
  under /dev immediately (which is excessive and prone to search
  problems).
* mkfs, mkfs.bfs: Don't complete "/path/to/file" literally.  I assume
  this was copy/pasted from example code, since it does not appear to be
  a valid argument unless it is a valid path, which is rare.
* fsck.cramfs, mkfs, mkfs.bfs, mkfs.cramfs, mkswap: Don't complete on
  all filenames initially.  The desired behavior is to complete
  filenames only if there are no canonical matches.[1]

Note: A subsequent commit will add the desired fallback behavior.

[1]: https://github.com/karelzak/util-linux/issues/842#issuecomment-523450243

Signed-off-by: Kevin Locke &lt;kevin@kevinlocke.name&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Some of the fsck and mkfs commands complete differently than the others,
and differently than the desired behavior.[1]  Standardize on completing
with $(lsblk -pnro name):

* fsck: Don't complete completes on all block devices and device links
  under /dev immediately (which is excessive and prone to search
  problems).
* mkfs, mkfs.bfs: Don't complete "/path/to/file" literally.  I assume
  this was copy/pasted from example code, since it does not appear to be
  a valid argument unless it is a valid path, which is rare.
* fsck.cramfs, mkfs, mkfs.bfs, mkfs.cramfs, mkswap: Don't complete on
  all filenames initially.  The desired behavior is to complete
  filenames only if there are no canonical matches.[1]

Note: A subsequent commit will add the desired fallback behavior.

[1]: https://github.com/karelzak/util-linux/issues/842#issuecomment-523450243

Signed-off-by: Kevin Locke &lt;kevin@kevinlocke.name&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>bash-completion: Exclude /dev/fd from fsck find</title>
<updated>2017-10-30T20:12:55+00:00</updated>
<author>
<name>Kevin Locke</name>
<email>kevin@kevinlocke.name</email>
</author>
<published>2017-10-30T19:50:51+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/util-linux.git/commit/?id=d22c1f533275ebf7060d9aa6dffc3ef265e81176'/>
<id>d22c1f533275ebf7060d9aa6dffc3ef265e81176</id>
<content type='text'>
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 &lt;kevin@kevinlocke.name&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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 &lt;kevin@kevinlocke.name&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix: list all block device from /dev and all symbolic links to block devices</title>
<updated>2016-10-04T12:48:06+00:00</updated>
<author>
<name>Richard Yann</name>
<email>yann.richard@uhb.fr</email>
</author>
<published>2016-10-04T12:48:06+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/util-linux.git/commit/?id=219452a47cc5966df8906a5dbe67250c13cef9a8'/>
<id>219452a47cc5966df8906a5dbe67250c13cef9a8</id>
<content type='text'>
Before fix "fsck -y /d&lt;tab&gt;" will never show LVM VG from multipath or mapped devices
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Before fix "fsck -y /d&lt;tab&gt;" will never show LVM VG from multipath or mapped devices
</pre>
</div>
</content>
</entry>
<entry>
<title>bash-completion: remove unused variables [shellcheck]</title>
<updated>2015-06-08T10:09:54+00:00</updated>
<author>
<name>Boris Egorov</name>
<email>egorov@linux.com</email>
</author>
<published>2015-06-02T17:59:03+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/util-linux.git/commit/?id=5e3da11b3e6c937c11953e2529b849b79ccac88e'/>
<id>5e3da11b3e6c937c11953e2529b849b79ccac88e</id>
<content type='text'>
Fix shellcheck SC2034 warnings.

Signed-off-by: Boris Egorov &lt;egorov@linux.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix shellcheck SC2034 warnings.

Signed-off-by: Boris Egorov &lt;egorov@linux.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>bash-completion: stop being clever when listing block devices</title>
<updated>2014-10-31T09:39:00+00:00</updated>
<author>
<name>Sami Kerola</name>
<email>kerolasa@iki.fi</email>
</author>
<published>2014-10-26T22:07:08+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/util-linux.git/commit/?id=53154dae39cd16924c97754589ed5396a91946bd'/>
<id>53154dae39cd16924c97754589ed5396a91946bd</id>
<content type='text'>
Various commands such as blkid, cfdisk, fdisk, delpart, and so on listed
only partitions and missed for example disks and volume groups.  The
right thing to do is to list all block devices in all for all commands
performing operations with them.  This might occasionally list unexpected
devices that I think is lesser bad than missing some.

Addresses: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=764488
Signed-off-by: Sami Kerola &lt;kerolasa@iki.fi&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Various commands such as blkid, cfdisk, fdisk, delpart, and so on listed
only partitions and missed for example disks and volume groups.  The
right thing to do is to list all block devices in all for all commands
performing operations with them.  This might occasionally list unexpected
devices that I think is lesser bad than missing some.

Addresses: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=764488
Signed-off-by: Sami Kerola &lt;kerolasa@iki.fi&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>bash-completion: Don't offer any more completions after help or version.</title>
<updated>2013-04-08T15:06:52+00:00</updated>
<author>
<name>Ville Skyttä</name>
<email>ville.skytta@iki.fi</email>
</author>
<published>2013-04-07T08:12:04+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/util-linux.git/commit/?id=d4f9b8d74c5110c6ee92483facd7a0d94a1a9e57'/>
<id>d4f9b8d74c5110c6ee92483facd7a0d94a1a9e57</id>
<content type='text'>
Signed-off-by: Ville Skyttä &lt;ville.skytta@iki.fi&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Ville Skyttä &lt;ville.skytta@iki.fi&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>bash-completion: rename shell-completion -&gt; bash-completion</title>
<updated>2013-04-05T12:58:07+00:00</updated>
<author>
<name>Karel Zak</name>
<email>kzak@redhat.com</email>
</author>
<published>2013-04-05T12:58:07+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/util-linux.git/commit/?id=20da58084a68b118b15fa01228192463b61fa28f'/>
<id>20da58084a68b118b15fa01228192463b61fa28f</id>
<content type='text'>
Signed-off-by: Karel Zak &lt;kzak@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Karel Zak &lt;kzak@redhat.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
