Skip to content
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

Clean up unused modules #101

Merged
merged 1 commit into from
Jun 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 0 additions & 18 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,21 +38,3 @@ jobs:
args: --timeout 5m
- name: 'Run unit tests core module'
run: go test -v ./core/...
#Model module
- name: 'Run linters model module'
uses: golangci/golangci-lint-action@v3
with:
working-directory: 'model'
version: v1.50
args: --timeout 5m
- name: 'Run unit tests model module'
run: go test -v ./model/...
#Contentadrstorage module
- name: 'Run linters contentadrstorage module'
uses: golangci/golangci-lint-action@v3
with:
working-directory: 'contentadrstorage'
version: v1.50
args: --timeout 5m
- name: 'Run unit tests contentadrstorage module'
run: go test -v ./contentadrstorage/...
18 changes: 1 addition & 17 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,24 +1,8 @@
packages = ./model/... ./core/... ./contract/... ./contentadrstorage/...
packages = ./core/... ./contract/...

.PHONY: test
test:
go test ${packages}

lint:
docker run --rm -v ${PWD}:/app -w /app golangci/golangci-lint:v1.50 golangci-lint run ${packages}

protobuf:
docker run --rm \
-v ${PWD}/ddc-schemas/storage/protobuf:/proto_path \
-v ${PWD}/model:/go_out \
rvolosatovs/protoc:3.3 \
--experimental_allow_proto3_optional \
--proto_path=/proto_path \
--go_out=/go_out \
$$(find ddc-schemas/storage/protobuf -name '*.proto' -type f | sed 's/.*\///')

protoc:
protoc --proto_path=./ddc-schemas/storage/protobuf --go_out=./model ./ddc-schemas/storage/**/*.proto

fix-docker-mess:
sudo chown $$(whoami) -R model/pb/
24 changes: 0 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,27 +1,3 @@
# cere-ddc-sdk-go

The Cere DDC SDK for Go.


## How to update the Protobuf schema

Clone the ddc-schemas repo:

git submodule update --init

Checkout a particular version of the schema:

cd ddc-schemas && git checkout storage-vX.X.X

Regenerate the code through a Docker image

make protobuf

… or through the `protoc` command …

make protoc

Freeze the schema version and generated code

git add ddc-schemas model/pb

3 changes: 0 additions & 3 deletions contentadrstorage/go.mod

This file was deleted.

Empty file removed contentadrstorage/go.sum
Empty file.
6 changes: 0 additions & 6 deletions contentadrstorage/pkg/pieceuri.go

This file was deleted.

142 changes: 0 additions & 142 deletions contentadrstorage/pkg/storage.go

This file was deleted.

2 changes: 0 additions & 2 deletions go.work
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,8 @@ go 1.18

use (
./blockchain
./contentadrstorage
./contract
./core
./model
./test
dac
)
3 changes: 1 addition & 2 deletions go.work.sum
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,6 @@ github.com/AzureAD/microsoft-authentication-library-for-go v0.6.0 h1:XMEdVDFxgul
github.com/AzureAD/microsoft-authentication-library-for-go v0.6.0/go.mod h1:BDJ5qMFKx9DugEg3+uQSDCdbYPr5s9vBTrL9P8TpqOU=
github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ=
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802 h1:1BDTz0u9nC3//pOCMdNH+CiXJVYJh5UQNCOBG7jbELc=
github.com/Cerebellum-Network/cere-substrate-rpc-client-go/v4 v4.0.0-20240528103741-c0b9d7116ed4 h1:JN3HK887OsgrpAuinStxbsVHpdiVFgAFdizDnRjE1qU=
github.com/Cerebellum-Network/cere-substrate-rpc-client-go/v4 v4.0.0-20240528103741-c0b9d7116ed4/go.mod h1:k61SBXqYmnZO4frAJyH3iuqjolYrYsq79r8EstmklDY=
github.com/DATA-DOG/go-sqlmock v1.3.3 h1:CWUqKXe0s8A2z6qCgkP4Kru7wC11YoAnoupUKFDnH08=
github.com/Microsoft/hcsshim v0.9.7 h1:mKNHW/Xvv1aFH87Jb6ERDzXTJTLPlmzfZ28VBFD/bfg=
github.com/Microsoft/hcsshim v0.9.7/go.mod h1:7pLA8lDk46WKDWlVsENo92gC0XFa8rbKfyFRBqxEbCc=
Expand Down Expand Up @@ -664,6 +662,7 @@ golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc
golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU=
golang.org/x/tools v0.13.0/go.mod h1:HvlwmtVNQAhOuCjW7xxvovg8wbNq7LwfXh/k7wXUl58=
golang.org/x/tools v0.17.0/go.mod h1:xsh6VxdV005rRVaS6SSAf9oiAqljS7UZUacMZ8Bnsps=
golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 h1:go1bK/D/BFZV2I8cIQd1NKEZ+0owSTG1fDTci4IqFcE=
gonum.org/v1/gonum v0.6.0 h1:DJy6UzXbahnGUf1ujUNkh/NEtK14qMo2nvlBPs4U5yw=
gonum.org/v1/netlib v0.0.0-20190313105609-8cb42192e0e0 h1:OE9mWmgKkjJyEmDAAtGMPjXu+YNeGvK9VTSHY6+Qihc=
gonum.org/v1/plot v0.0.0-20190515093506-e2840ee46a6b h1:Qh4dB5D/WpoUUp3lSod7qgoyEHbDGPUWjIbnqdqqe1k=
Expand Down
54 changes: 0 additions & 54 deletions model/ddcuri/ddcuri.go

This file was deleted.

41 changes: 0 additions & 41 deletions model/ddcuri/ddcuri_gen.go

This file was deleted.

Loading
Loading