Community Packages

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#68587 - [lsd] add shell completion files to package

Attached to Project: Community Packages
Opened by xduugu (xduugu) - Tuesday, 10 November 2020, 22:28 GMT
Last edited by Orhun Parmaksız (orhun) - Monday, 25 January 2021, 15:05 GMT
Task Type Feature Request
Category Packages
Status Closed
Assigned To Orhun Parmaksız (orhun)
Architecture All
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

lsd provides shell completion files, but they are not generated by default. It is necessary to set the environment variable SHELL_COMPLETIONS_DIR when building lsd to generate them.

The following changes are required to add the completion files to the package:

- Prefix the cargo build line in the build function with the environment variable:

build() {
cd "$pkgname-$pkgver"
SHELL_COMPLETIONS_DIR=completions cargo build --release --locked
}

- Move the completion files to the shell completion directories in the package function:

# shell completions
install -Dm644 "completions/$pkgname.bash" "$pkgdir/usr/share/bash-completion/completions/$pkgname"
install -Dm644 "completions/$pkgname.fish" "$pkgdir/usr/share/fish/vendor_completions.d/$pkgname.fish"
install -Dm644 "completions/_$pkgname" "$pkgdir/usr/share/zsh/site-functions/_$pkgname"
This task depends upon

Closed by  Orhun Parmaksız (orhun)
Monday, 25 January 2021, 15:05 GMT
Reason for closing:  Implemented
Comment by Orhun Parmaksız (orhun) - Monday, 25 January 2021, 15:04 GMT
Shell completions are now available via 0.19.0-1 release.

Loading...