-
Notifications
You must be signed in to change notification settings - Fork 13
Fix starship builds #228
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
SuperMatt
wants to merge
1
commit into
pkgforge:main
Choose a base branch
from
SuperMatt:fix-starship
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Fix starship builds #228
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
builds were failing on amd64 hosts due to xargs realpath missing it's operand with the following error:
```
realpath: missing operand
```
The fix for this is relatively simple, add -I "{}" back in to the xargs options, and then add "{}" to the realpath.
Further, the aarch64 builds were failing because it was downloading file `starship-aarch64-apple-darwin.tar.gz`. Macos was listed in the ignored file names list, but that's not in the name and apple and darwin were still allowed, so I've added them to the ignore list.
Author
|
part of issue #229 |
SuperMatt
added a commit
to SuperMatt/soarpkgs
that referenced
this pull request
Dec 31, 2025
The existing fish script was not building correctly so it had never produced a fish binary based on the upstream. As fish provides pre-build binaries, it would be much better to just use those. I have switched from building from source to downloading, using a very similar method to starship (as I've just worked on a PR for that, see pkgforge#228). Here's a copy of the build output: ``` $ sbuild build ./static.official.source.yaml --keep --outdir ./SBUILD-TEST sbuild v0.1.10 INFO Building: ./static.official.source.yaml Linting ./static.official.source.yaml (/home/matthew/gits/soarpkgs/binaries/fish/./static.official.source.yaml) Performing shellcheck [✔] Shellcheck passed [✔] Fetched version (4.3.2) using x_exec.pkgver written to ./static.official.source.yaml.pkgver SBUILD validation successful. Validated YAML has been written to ./static.official.source.yaml.validated _disabled: false pkg: "fish" pkg_id: "github.com.fish-shell.fish-shell" pkg_type: "static" category: - "ConsoleOnly" - "Utility" description: "Smart and User-friendly Command Line Shell" distro_pkg: alpine: - "fish" archlinux: aur: - "fish-git" extra: - "fish" debian: - "fish" gnuguix: - "fish" homebrew: - "fish" nixpkgs: - "fish" - "fishMinimal" stalix: - "bin/fish" homepage: - "https://github.com/fish-shell/fish-shell" maintainer: - "Azathothas (https://github.com/Azathothas)" license: - id: "Custom" url: "https://github.com/fish-shell/fish-shell/raw/8617964d4dbf03d752fbf094600ef977a36a83ec/COPYING" note: - "[DO NOT RUN] (Meant for pkgforge CI Only)" - "Built From Source (Latest Git HEAD). Check/Report @ https://github.com/fish-shell/fish-shell" provides: - "fish" repology: - "fish" src_url: - "https://github.com/fish-shell/fish-shell" tag: - "Utility" x_exec: host: - "aarch64-linux" - "x86_64-linux" shell: "bash" pkgver: | curl -qfsSL "https://api.gh.pkgforge.dev/repos/fish-shell/fish-shell/releases?per_page=100" | jq -r '[.[] | select(.draft == false)] | .[0].tag_name | gsub("\\s+"; "")' | tr -d '"'\''[:space:]' run: | #Download case "$(uname -m)" in aarch64) soar dl "https://github.com/fish-shell/fish-shell@${PKGVER}" --match "linux,aarch64,musl,tar" --exclude "amd64,x86,x64,sha256,sha512,bsd,macos,windows" -o "${SBUILD_TMPDIR}/${PKG}.archive" --yes ;; x86_64) soar dl "https://github.com/fish-shell/fish-shell@${PKGVER}" --match "linux,x86_64,musl,tar" --exclude "aarch,arm,i386,i686,sha256,sha512,bsd,macos,windows" -o "${SBUILD_TMPDIR}/${PKG}.archive" --yes ;; esac #Extract while E_X=$(find "${SBUILD_TMPDIR}" -type f -exec file -i "{}" + | grep -Ei "archive|compressed|gzip|x-compress|x-tar" | grep -iv "application/.*executable" | cut -d: -f1 | head -n1); [ -n "${E_X}" ] do 7z e "${E_X}" -o"${SBUILD_TMPDIR}/." -y && { file -i "${E_X}" | grep -q "application/.*executable" && break rm -f "${E_X}" } || break done #Copy find "${SBUILD_TMPDIR}" -maxdepth 1 -type f -exec file -i "{}" \; | grep -Ei "application/.*executable|inode/symlink|text/x-perl|text/.*script" | cut -d":" -f1 | xargs realpath --no-symlinks | xargs -I "{}" rsync -achvL "{}" "${SBUILD_OUTDIR}/${PKG}" Downloading license from https://github.com/fish-shell/fish-shell/raw/8617964d4dbf03d752fbf094600ef977a36a83ec/COPYING to LICENSE Detected GitHub URL, processing as GitHub release Found release: 4.3.2 Downloading asset: fish-4.3.2-linux-aarch64.tar.xz 7-Zip (z) 25.01 (arm64) : Copyright (c) 1999-2025 Igor Pavlov : 2025-08-03 64-bit arm_v:8-A locale=C.UTF-8 Threads:4 OPEN_MAX:1024, ASM Scanning the drive for archives: 1 file, 2824572 bytes (2759 KiB) Extracting archive: /home/matthew/gits/soarpkgs/binaries/fish/./SBUILD-TEST/github.com.fish-shell.fish-shell/SBUILD_TEMP/fish.archive -- Path = /home/matthew/gits/soarpkgs/binaries/fish/./SBUILD-TEST/github.com.fish-shell.fish-shell/SBUILD_TEMP/fish.archive Type = xz Physical Size = 2824572 Method = LZMA2:23 CRC64 Streams = 1 Blocks = 1 Everything is Ok Size: 14213120 Compressed: 2824572 7-Zip (z) 25.01 (arm64) : Copyright (c) 1999-2025 Igor Pavlov : 2025-08-03 64-bit arm_v:8-A locale=C.UTF-8 Threads:4 OPEN_MAX:1024, ASM Scanning the drive for archives: 1 file, 14213120 bytes (14 MiB) Extracting archive: /home/matthew/gits/soarpkgs/binaries/fish/./SBUILD-TEST/github.com.fish-shell.fish-shell/SBUILD_TEMP/fish -- Path = /home/matthew/gits/soarpkgs/binaries/fish/./SBUILD-TEST/github.com.fish-shell.fish-shell/SBUILD_TEMP/fish Type = tar Physical Size = 14213120 Headers Size = 7680 Code Page = UTF-8 Characteristics = GNU ASCII Everything is Ok Size: 14205264 Compressed: 14213120 sending incremental file list fish sent 14.21M bytes received 35 bytes 28.42M bytes/sec total size is 14.21M speedup is 1.00 [✔] Successfully built the package at /home/matthew/gits/soarpkgs/binaries/fish/./SBUILD-TEST/github.com.fish-shell.fish-shell INFO Generating checksums... INFO Checksums generated [+] 1 of 1 packages built successfully [⏱] Completed in 2.85s ```
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
builds were failing on amd64 hosts due to xargs realpath missing it's operand with the following error:
The fix for this is relatively simple, add
-I "{}"back in to the xargs options, and then add"{}"to the realpath.Further, the aarch64 builds were failing because it was downloading file
starship-aarch64-apple-darwin.tar.gz. Macos was listed in the ignored file names list, but that's not in the name and apple and darwin were still allowed, so I've added them to the ignore list.