-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 398b3e2
Showing
60 changed files
with
7,794 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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,63 @@ | ||
./main | ||
|
||
*.log | ||
*~ | ||
.DS_Store | ||
|
||
awscpu | ||
|
||
# Binaries for programs and plugins | ||
*.exe | ||
*.exe~ | ||
*.dll | ||
*.so | ||
*.dylib | ||
*.profile | ||
|
||
# Test binary, build with `go test -c` | ||
*.test | ||
|
||
# Output of the go coverage tool, specifically when used with LiteIDE | ||
*.out | ||
|
||
# ignore GoLand metafiles directory | ||
.idea/ | ||
|
||
*logs/ | ||
|
||
.vscode* | ||
.env | ||
|
||
*.pb* | ||
|
||
# db* | ||
|
||
*cpu[0-9]* | ||
*mem[0-9]* | ||
*lock[0-9]* | ||
*.profile | ||
*.txt | ||
*.swp | ||
*.aux | ||
*.fdb* | ||
*.fls | ||
*.gz | ||
|
||
.coverage | ||
|
||
bin/ | ||
build/ | ||
vendor | ||
|
||
.blob-cli-pk | ||
genesis.json | ||
*.test | ||
|
||
dist/ | ||
tmp-storage-testing | ||
deploys/ | ||
.nuklai-cli* | ||
*.coverage.html | ||
data/ | ||
osxcross/ |
This file contains 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,116 @@ | ||
# Copyright (C) 2023, AllianceBlock. All rights reserved. | ||
# See the file LICENSE for licensing terms. | ||
|
||
# https://golangci-lint.run/usage/configuration/ | ||
run: | ||
timeout: 10m | ||
# skip auto-generated files. | ||
skip-files: | ||
- ".*\\.pb\\.go$" | ||
- '.*mock.*' | ||
|
||
issues: | ||
# Maximum count of issues with the same text. Set to 0 to disable. Default is 3. | ||
max-same-issues: 0 | ||
|
||
linters: | ||
# please, do not use `enable-all`: it's deprecated and will be removed soon. | ||
# inverted configuration with `enable-all` and `disable` is not scalable during updates of golangci-lint | ||
disable-all: true | ||
enable: | ||
- asciicheck | ||
- depguard | ||
- errcheck | ||
- errorlint | ||
- exportloopref | ||
- goconst | ||
- gocritic | ||
- gofmt | ||
- gofumpt | ||
- goimports | ||
- revive | ||
- gosec | ||
- gosimple | ||
- govet | ||
- ineffassign | ||
- misspell | ||
- nakedret | ||
- nolintlint | ||
- prealloc | ||
- stylecheck | ||
- unconvert | ||
- unparam | ||
- unused | ||
- unconvert | ||
- whitespace | ||
- staticcheck | ||
- bodyclose | ||
- structcheck | ||
# - lll | ||
# - gomnd | ||
- goprintffuncname | ||
- interfacer | ||
- typecheck | ||
# - goerr113 | ||
- noctx | ||
|
||
linters-settings: | ||
errorlint: | ||
# Check for plain type assertions and type switches. | ||
asserts: false | ||
# Check for plain error comparisons. | ||
comparison: false | ||
revive: | ||
rules: | ||
# https://github.com/mgechev/revive/blob/master/RULES_DESCRIPTIONS.md#bool-literal-in-expr | ||
- name: bool-literal-in-expr | ||
disabled: false | ||
# https://github.com/mgechev/revive/blob/master/RULES_DESCRIPTIONS.md#early-return | ||
- name: early-return | ||
disabled: false | ||
# https://github.com/mgechev/revive/blob/master/RULES_DESCRIPTIONS.md#empty-lines | ||
- name: empty-lines | ||
disabled: false | ||
# https://github.com/mgechev/revive/blob/master/RULES_DESCRIPTIONS.md#struct-tag | ||
- name: struct-tag | ||
disabled: false | ||
# https://github.com/mgechev/revive/blob/master/RULES_DESCRIPTIONS.md#unexported-naming | ||
- name: unexported-naming | ||
disabled: false | ||
# https://github.com/mgechev/revive/blob/master/RULES_DESCRIPTIONS.md#unhandled-error | ||
- name: unhandled-error | ||
disabled: false | ||
arguments: | ||
- 'fmt.Fprint' | ||
- 'fmt.Fprintf' | ||
- 'fmt.Print' | ||
- 'fmt.Printf' | ||
- 'fmt.Println' | ||
- 'rand.Read' | ||
- 'sb.WriteString' | ||
# https://github.com/mgechev/revive/blob/master/RULES_DESCRIPTIONS.md#unused-parameter | ||
- name: unused-parameter | ||
disabled: false | ||
# https://github.com/mgechev/revive/blob/master/RULES_DESCRIPTIONS.md#unused-receiver | ||
- name: unused-receiver | ||
disabled: false | ||
# https://github.com/mgechev/revive/blob/master/RULES_DESCRIPTIONS.md#useless-break | ||
- name: useless-break | ||
disabled: false | ||
staticcheck: | ||
go: '1.20' | ||
# https://staticcheck.io/docs/options#checks | ||
checks: | ||
- 'all' | ||
- '-SA6002' # argument should be pointer-like to avoid allocation, for sync.Pool | ||
- '-SA1019' # deprecated packages e.g., golang.org/x/crypto/ripemd160 | ||
# https://golangci-lint.run/usage/linters#gosec | ||
gosec: | ||
excludes: | ||
- G107 # https://securego.io/docs/rules/g107.html | ||
depguard: | ||
list-type: blacklist | ||
packages-with-error-message: | ||
- io/ioutil: 'io/ioutil is deprecated. Use package io or os instead.' | ||
- github.com/stretchr/testify/assert: 'github.com/stretchr/testify/require should be used instead.' | ||
include-go-root: true |
This file contains 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,75 @@ | ||
# Copyright (C) 2023, AllianceBlock. All rights reserved. | ||
# See the file LICENSE for licensing terms. | ||
|
||
# ref. https://goreleaser.com/customization/build/ | ||
builds: | ||
- id: nuklai-cli | ||
main: ./cmd/nuklai-cli | ||
binary: nuklai-cli | ||
flags: | ||
- -v | ||
goos: | ||
- linux | ||
- darwin | ||
goarch: | ||
- amd64 | ||
- arm64 | ||
env: | ||
- CGO_ENABLED=1 | ||
- CGO_CFLAGS=-O -D__BLST_PORTABLE__ # Set the CGO flags to use the portable version of BLST | ||
overrides: | ||
- goos: linux | ||
goarch: arm64 | ||
env: | ||
- CC=aarch64-linux-gnu-gcc | ||
- goos: darwin | ||
goarch: arm64 | ||
env: | ||
- CC=oa64-clang | ||
- goos: darwin | ||
goarch: amd64 | ||
goamd64: v1 | ||
env: | ||
- CC=o64-clang | ||
- id: nuklaivm | ||
main: ./cmd/nuklaivm | ||
binary: nuklaivm | ||
flags: | ||
- -v | ||
goos: | ||
- linux | ||
- darwin | ||
goarch: | ||
- amd64 | ||
- arm64 | ||
env: | ||
- CGO_ENABLED=1 | ||
- CGO_CFLAGS=-O -D__BLST_PORTABLE__ # Set the CGO flags to use the portable version of BLST | ||
overrides: | ||
- goos: linux | ||
goarch: arm64 | ||
env: | ||
- CC=aarch64-linux-gnu-gcc | ||
- goos: darwin | ||
goarch: arm64 | ||
env: | ||
- CC=oa64-clang | ||
- goos: darwin | ||
goarch: amd64 | ||
goamd64: v1 | ||
env: | ||
- CC=o64-clang | ||
|
||
checksum: | ||
name_template: 'nuklaivm_checksums.txt' | ||
|
||
archives: | ||
- id: default | ||
name_template: 'nuklaivm_{{ .Version }}_{{ .Os }}_{{ .Arch }}' | ||
|
||
release: | ||
make_latest: false # Should be done manually | ||
mode: 'keep-existing' # Should not override releases | ||
github: | ||
owner: ava-labs | ||
name: hypersdk |
This file contains 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,21 @@ | ||
MIT License | ||
|
||
Copyright (c) 2023 AllianceBlock. All rights reserved. | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
Oops, something went wrong.