mirror of
https://gitlab.com/pulsechaincom/prysm-pulse.git
synced 2024-12-22 03:30:35 +00:00
3e2a037d42
* github workflows: pin go version to 1.17 * Update go.yml * Revert "Update go.yml" This reverts commit 4a2d36d05d8bf45debd24162952c30d830d09572. * pin golangci-lint * try go 1.17 * Revert "Revert "Update go.yml"" This reverts commit 8a89663874013e84c9f39ff30c7b45978ec8fdf5. * move and increase version of checkout * attempt to ignore export path * try with entrypoint only * try some rearranging of stuff * Split up jobs * Use hack mentioned in https://github.com/securego/gosec/issues/469\#issuecomment-643823092 * Delete dappnode release trigger * rm id * try pin golangci-lint version * try pin golangci-lint version * Do not provide a specific go version and lets see what happens * comment checkout, wtf is wrong with github actions * it works locally... * trying with some cache key for lint... * Revert "trying with some cache key for lint..." This reverts commit c4f5ae4495e8f568ba78e8004b8fb86d5137bf66. * try tellign it to skip go installation * revert commented line, do something to satisify deepsource * do something to satisify deepsource
35 lines
721 B
Bash
Executable File
35 lines
721 B
Bash
Executable File
#!/bin/sh -l
|
|
set -e
|
|
export PATH="$PATH:/usr/local/go/bin"
|
|
|
|
cd "$GITHUB_WORKSPACE"
|
|
|
|
cp go.mod go.mod.orig
|
|
cp go.sum go.sum.orig
|
|
|
|
go mod tidy -compat=1.17
|
|
|
|
echo "Checking go.mod and go.sum:"
|
|
checks=0
|
|
if [ "$(diff -s go.mod.orig go.mod | grep -c 'Files go.mod.orig and go.mod are identical')" = 1 ]; then
|
|
echo "- go.mod is up to date."
|
|
checks=$((checks + 1))
|
|
else
|
|
echo "- go.mod is NOT up to date."
|
|
fi
|
|
|
|
if [ "$(diff -s go.sum.orig go.sum | grep -c 'Files go.sum.orig and go.sum are identical')" = 1 ]; then
|
|
echo "- go.sum is up to date."
|
|
checks=$((checks + 1))
|
|
else
|
|
echo "- go.sum is NOT up to date."
|
|
fi
|
|
|
|
if [ $checks -eq 2 ]; then
|
|
exit 0
|
|
fi
|
|
|
|
# Notify of any issues.
|
|
echo "Run 'go mod tidy' to update."
|
|
exit 1
|