forked from multiversx/mx-bridge-eth-go
-
Notifications
You must be signed in to change notification settings - Fork 0
[KLC-1663] Fix build workflow #15
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
Merged
Merged
Changes from 3 commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
ef51e67
change slowTests proxy interface to klever blockchain implementation
RomuloSiebra e98c135
change executor to klever blockchain proxy implementation
RomuloSiebra 87a8840
update build workflow with cache and repository variables
RomuloSiebra a29f77d
change modvendor version to static v1.8.3
RomuloSiebra File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,76 @@ | ||
| name: 'Go Setup Action' | ||
| description: 'Sets up Go environment with private modules support and caching' | ||
| inputs: | ||
| go-version: | ||
| description: 'The Go version to use' | ||
| required: false | ||
| default: '1.22.1' | ||
| go-private: | ||
| description: 'Private go modules' | ||
| required: false | ||
| default: 'github.com/klever-io/*' | ||
| cache-enabled: | ||
| description: 'Enable caching of Go modules' | ||
| required: false | ||
| default: 'true' | ||
| git-user: | ||
| description: 'Git username for private modules' | ||
| required: false | ||
| git-pass: | ||
| description: 'Git password or token for private modules' | ||
| required: false | ||
|
|
||
| runs: | ||
| using: "composite" | ||
| steps: | ||
| - name: Set up Golang | ||
| uses: actions/setup-go@v5 | ||
| with: | ||
| go-version: ${{ inputs.go-version }} | ||
| cache: false | ||
|
|
||
| - name: Configure git for private modules | ||
| if: inputs.git-user != '' && inputs.git-pass != '' | ||
| shell: bash | ||
| run: | | ||
| git config --global url."https://${{ inputs.git-user }}:${{ inputs.git-pass }}@github.com".insteadOf "https://github.com" | ||
|
|
||
| - name: Cache Go dependencies | ||
| id: cache_vendor | ||
| if: inputs.cache-enabled == 'true' | ||
| uses: actions/cache@v4 | ||
RomuloSiebra marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| env: | ||
| cache-name: go-cache-vendor | ||
| with: | ||
| path: | | ||
| ~/go/pkg/mod | ||
| ./vendor | ||
| key: ${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('**/go.sum') }} | ||
| restore-keys: | | ||
| ${{ runner.os }}-${{ env.cache-name }}- | ||
| enableCrossOsArchive: true | ||
|
|
||
| - name: Resolve package to module & Download dependencies | ||
| if: ${{ steps.cache_vendor.outputs.cache-hit != 'true' }} | ||
| shell: bash | ||
| run: | | ||
| go mod tidy | ||
| go mod download | ||
|
|
||
| - name: Generate Vendor and Install modvendor | ||
| if: ${{ steps.cache_vendor.outputs.cache-hit != 'true' }} | ||
| shell: bash | ||
| run: | | ||
| go install github.com/goware/modvendor@latest | ||
| go mod vendor | ||
| modvendor -copy="**/*.c **/*.h **/*.proto **/*.a" | ||
|
|
||
coderabbitai[bot] marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| - name: Verify no changes from go mod tidy | ||
| shell: bash | ||
| run: | | ||
| go mod tidy | ||
| if [ -n "$(git status --porcelain)" ]; then | ||
| echo "Changes found after go mod tidy:" | ||
| git status --porcelain | ||
| exit 1 | ||
| fi | ||
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
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
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
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
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
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
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.
Uh oh!
There was an error while loading. Please reload this page.