Sniprun AUR package #58
Replies: 4 comments 13 replies
-
Sure, i guess some dependencies are not quite up to date in there. I'll try to keep them up to date manually, since i guess that "*" dependencies are so-so and that there is not way to automate that like the pkgver.....but if there is a way, i'll take it :-). Maybe a github bot? Or maybe "*" dependencies in cargo.toml are ok, and then updating the lock is only one 'cargo update' away? You tell me I also use Arch and i have a few packages up there myself I think what need some attention is the (new) issue with neovim 0.4.x vs 0.5 stuff. |
Beta Was this translation helpful? Give feedback.
-
This is what I have thus far. It's a split package because the vim and Rust components come from the same upstream. # Maintainer: lmartinez-mirror
pkgname=('sniprun' 'neovim-sniprun')
pkgver=0.5.2
pkgrel=1
pkgdesc='A neovim plugin to independently run snippets of code'
arch=('x86_64')
url="https://github.com/michaelb/sniprun"
license=('MIT')
makedepends=('cargo' 'gcc-libs')
source=("$pkgname-$pkgver.tar.gz::$url/archive/refs/tags/v$pkgver.tar.gz")
sha256sums=('97d952f54235cf5b52553cafbb9466b2f83dbc1c562279b9ce940dfc308a00c7')
build() {
cd "$pkgname-$pkgver"
cargo build --release --all-features --target-dir=target
}
# check() {
# cd "$pkgname-$pkgver"
# cargo test --release --locked --target-dir=target
# }
package_sniprun() {
pkgdesc='Compiled binary core for neovim-sniprun'
depends=('gcc-libs')
cd "$pkgname-$pkgver"
install -Dm 755 target/release/sniprun -t "$pkgdir/usr/bin/"
install -Dm 644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname/"
install -Dm 644 README.md -t "$pkgdir/usr/share/doc/$pkgname/"
}
package_neovim-sniprun() {
arch=('any')
depends=('neovim-git' 'sniprun')
optdepends=('bash: Bash snippet support'
'gcc: C snippets support'
'gcc-ada: Limited Ada snippet support'
'ghc: Haskell snippets support'
'g++: C++ snippets support'
'python3: Python3 snippets support'
'jupyter: Jupyter support'
'jupyter_console: Required with jupyter')
install="$pkgname.install"
cd "sniprun-$pkgver"
find autoload doc plugin lua \
-type f -exec install -Dm 644 '{}' "$pkgdir/usr/share/nvim/runtime/{}" \;
install -d "$pkgdir/usr/share/nvim/runtime/target/release"
ln -s "/usr/bin/sniprun" "$pkgdir/usr/share/nvim/runtime/target/release/sniprun"
install -d "$pkgdir/usr/share/licenses/"
install -d "$pkgdir/usr/share/doc/"
ln -s "/usr/share/licenses/sniprun/" "$pkgdir/usr/share/licenses/$pkgname"
ln -s "/usr/share/doc/sniprun" "$pkgdir/usr/share/doc/$pkgname"
} |
Beta Was this translation helpful? Give feedback.
-
I've tested the AUR version of sniprun, it works great. It's not a problem for general usage though, sniprun will restart by itself at the next call. The message about the bash interpreter is very thoughful. |
Beta Was this translation helpful? Give feedback.
-
This is a notice that I will be removing |
Beta Was this translation helpful? Give feedback.
-
Hi, I'm currently writing up several PKGBUILDs of sniprun for submitting into the AUR. One of the things Arch Linux has in their guidelines for Rust packages is using a Cargo.lock file for compiling.
It would be great to have an up-to-date Cargo.lock file in the current and future releases for this.
Beta Was this translation helpful? Give feedback.
All reactions