yazi/snap/snapcraft.yaml
2025-01-11 09:40:24 +00:00

57 lines
1.4 KiB
YAML

name: yazi
base: core24
adopt-info: yazi
summary: Blazing fast terminal file manager written in Rust, based on async I/O.
description: |
Yazi is a terminal file manager written in Rust, based on non-blocking async I/O.
It aims to provide an efficient, user-friendly, and customizable file management experience.
license: MIT
grade: stable
confinement: classic
platforms:
amd64:
arm64:
apps:
yazi:
command: yazi
environment:
PATH: $SNAP/bin:$SNAP/usr/bin:$PATH
parts:
yazi:
plugin: rust
source: https://github.com/sxyazi/yazi.git
stage-snaps:
- jq
stage-packages:
- 7zip
- fd-find
- ffmpeg
- fzf
- libpoppler-cpp0t64
- ripgrep
- zoxide
override-build: |
craftctl default
craftctl set version=$(git describe --tags --abbrev=0)
build-attributes:
- enable-patchelf
organize:
# Ubuntu's `fd` package installs a binary named `fdfind`. Rename it in the snap.
usr/bin/fdfind: usr/bin/fd
# The Ubuntu `imagemagick` package does not ship a `magick` binary,
# which `yazi` looks for. Building the package oursleves yields the
# expected binary without much overhead, and works across platforms.
magick:
plugin: autotools
source: https://imagemagick.org/archive/ImageMagick.tar.gz
source-type: tar
stage-packages:
- libgomp1
autotools-configure-parameters:
- --prefix=/usr
build-attributes:
- enable-patchelf