Files
packages/lang/golang/golang1.26/test.sh
T
George Sapkin d9fdda8cf2 golang: add a simple compilation test
Add a simple CI compilation test to ensure that the Go toolchain is
functional.

Signed-off-by: George Sapkin <george@sapk.in>
2026-05-14 00:24:08 +03:00

24 lines
301 B
Bash
Executable File

#!/bin/sh
#
# SPDX-License-Identifier: GPL-2.0-only
case "$1" in
golang*doc|golang*misc|golang*src|golang*tests) exit ;;
esac
go version | grep -F " go$PKG_VERSION "
cat <<'EOF' > hello.go
package main
import "fmt"
func main() {
fmt.Println("Hello, World!")
}
EOF
go run hello.go
rm hello.go