add buildx script

This commit is contained in:
zekroTJA
2024-12-24 15:50:02 +01:00
parent 1858652ff9
commit e5a01d86b3

17
bin/buildx Executable file
View File

@@ -0,0 +1,17 @@
#!/bin/bash
target=$(rustc --print target-list | fzf --cycle --header "Select build target:")
if [ -z "$target" ]; then
echo "No target selected. Canceled."
exit 1
fi
if [ -n "$1" ]; then
cmd="$1"
shift
else
cmd="build"
fi
cross "$cmd" --target "$target" $@