Skip to content
  • Ondrej Holy's avatar
    gio: Add bash completion for gio tool · e0e0f259
    Ondrej Holy authored
    GVfs utils used to have bash completion, which was pretty useful. However,
    it hasn't been ported to gio tool unfortunately. GLib provides completion
    for various utils already, so it would be nice to provide completion also
    for gio tool. I've updated old bash completion code and merged with some
    my old unmerged fixes.
    
    The gvfs completion used "gvfs-ls --show-completions" helper. This mentioned
    option hasn't been obviously ported to "gio list" and the proposed completion
    doesn't add this option in "gio list" to not pollute the codes, but maybe it
    is a bit slower as consequence.
    
    The proposed bash completion suggests subcommands, uris and paths including
    the remote mounts. It contains some workarounds, especially because of proper
    handling of paths with colons and other special chars (like spaces)...
    e0e0f259