← Back to issue list

Support snap installed completion scripts

View original Launchpad issue

Metadata

Project
snapcraft (launchpad)
Number
#1590767
Type
issue
State
closed
Author
~sergiusens
Labels
isv lxd
Created
Updated
Closed

Current evaluation

Resolved by snapd 2.28 automatic completion integration and snapcraft completer wiring in merged PR #1956 (commit 32fbaf3d4).

Resolution: closed resolved

Reason: Snapcraft merged the completer support in PR #1956 at commit 32fbaf3d4. Maintainer Chipaca confirmed that the basic work landed in snapd 2.26 and that snapd 2.28 would make completion automatic, enabling closure.

Evaluated by: mr-cal-bot

No scores available.

Issue body

I have just published a new snap named "tio" which includes a bash completion script but the completion script is not picked up on and enabled by the system once installed. The completion script gets installed in /snap/tio/current/usr/share/bash-completion/completions/tio This of course differs from the conventional install location and hence the script is not sourced. How do we safely enable sourcing of snap installed bash completion scripts?

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha — closed resolved Resolved by snapd 2.28 automatic completion integration and snapcraft completer wiring in merged PR #1956 (commit 32fbaf3d4).
stealth/space-bunny-alpha — closed resolved Snap-installed bash completion became automatic with snapd 2.28; Snapcraft completed completer wiring in merged PR #1956 (32fbaf3d4).
stealth/space-bunny-alpha — closed stale Snap-installed bash completion support was not implemented; the request received no follow-up and was closed without a documented resolution.
qwen/qwen3.6-35b-a3b — — Closed without action or comments. The request to automatically source bash completion scripts from non-standard snap paths remains unaddressed and appears abandoned.
qwen/qwen3.6-35b-a3b — — Abandoned. The request to automatically source bash completion scripts from snap packages was closed without implementation or discussion.
qwen/qwen3.6-35b-a3b — — Closed without implementation. The request to automatically source bash completion scripts from non-standard snap paths received no discussion or resolution.
qwen3.6-35b-a3b-mtp-q6 — — Closed without resolution or discussion. The request to automatically source bash completion scripts from snap packages remains unaddressed and appears abandoned.

Update history

Date Change
created

Related work

  • Likely Fixed By: snapcore/snapcraft#1956 (confidence 98%)

    Merged snapcraft change adding completer passthrough and wiring.

  • Related To: snapcore/snapcraft#1373 (confidence 80%)

    Earlier pull request cited as providing passthrough support for the completer.

Related issues

Issue Project State Summary Similarity
#1956 snap: actually plug the completer in. snapcraft merged PR #1956 merged as commit 32fbaf3d4, wiring the bundled completion.sh into snap metadata so Snapcraft exposes tab completion.
81%
#1751391 snapcraft's snap's snap.yaml doesn't plug in the completer snapcraft (launchpad) closed Snap completion was fixed by PR #1956 (commit 32fbaf3d4), adding completer: completion.sh to Snapcraft's snap app definition.
80%
#1570506 Snapcraft should use bash-completion snapcraft (launchpad) closed Added bash-completion support to snapcraft via merged upstream PR #453 (commit 6ea95fd50, changelog 16e1a9d76). Shipped in snapcraft 2.9 SRU to xenial; verified by elopio and released to -updates on 2016-05-30.
76%
#453 Add in bash completion snapcraft merged Merged PR #453 via commit 6ea95fd50, adding a simple Bash completion script for Snapcraft commands.
76%
#1390 meta: bash completion support snapcraft merged Merged PR #1390 added bash completion support for snapcraft and snapcraft metadata, landing as commit 2d01bc112.
76%
#1646213 Code completion for *.snap on the cli is broken snapcraft (launchpad) closed Fixed by merged canonical/snapcraft#933 (commit 5c41e4bc), which corrected Bash completion for .snap files containing multiple dots.
75%
#5218 feat: add improved bash completion script snapcraft merged Merged in #5218 (commit 387202653), replacing the manually maintained Bash completion with a dynamically generated script that tracks current commands and options; shipped in Snapcraft 8.7.
72%
#4559 bash-completion: update and improve supported completion cases snapcraft closed Completion work in canonical/snapcraft#4559 was closed as stale and superseded by canonical/craft-cli#319, merged in commit 4d41d7d with generated Bash completion.
70%
#1409 snap: remove completer entry snapcraft merged Merged PR #1409 as db235805a, removing the unsupported completer entry so snapcraft.yaml remained compatible with 2.32 pending 2.33 rollout on Xenial.
70%