Skip to content

Commit

Permalink
Merge pull request #1413 from onflow/feature/stable-cadence-merge-master
Browse files Browse the repository at this point in the history
Feature/stable cadence merge master
  • Loading branch information
nialexsan authored Feb 15, 2024
2 parents cac3052 + 84f3729 commit 752eb7b
Show file tree
Hide file tree
Showing 86 changed files with 70 additions and 20,196 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,12 @@ jobs:
fetch-depth: 0
- uses: actions/setup-go@v4
with:
go-version: '1.20'
go-version: "1.20"
- name: Run tests
run: |
make ci
make check-tidy
make check-headers
make check-schema
- name: Upload coverage report
uses: codecov/codecov-action@v1
with:
Expand Down
18 changes: 0 additions & 18 deletions .github/workflows/flowkit-release.yml

This file was deleted.

15 changes: 2 additions & 13 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ install-tools:
.PHONY: test
test:
GO111MODULE=on go test -coverprofile=$(COVER_PROFILE) $(if $(JSON_OUTPUT),-json,) ./...
cd flowkit; GO111MODULE=on go test -coverprofile=$(COVER_PROFILE) $(if $(JSON_OUTPUT),-json,) ./...

.PHONY: test-e2e-emulator
test-e2e-emulator:
Expand All @@ -58,7 +57,7 @@ $(BINARY):
GO111MODULE=on go build \
-trimpath \
-ldflags \
"-X github.com/onflow/flow-cli/build.commit=$(COMMIT) -X github.com/onflow/flow-cli/build.semver=$(VERSION) -X github.com/onflow/flow-cli/flowkit/util.MIXPANEL_PROJECT_TOKEN=${MIXPANEL_PROJECT_TOKEN} -X github.com/onflow/flow-cli/internal/accounts.accountToken=${ACCOUNT_TOKEN}"\
"-X github.com/onflow/flow-cli/build.commit=$(COMMIT) -X github.com/onflow/flow-cli/build.semver=$(VERSION) -X github.com/onflow/flow-cli/internal/accounts.accountToken=${ACCOUNT_TOKEN}"\
-o $(BINARY) ./cmd/flow

.PHONY: versioned-binaries
Expand Down Expand Up @@ -97,20 +96,10 @@ fix-lint:
check-headers:
@./check-headers.sh

.PHONY: check-schema
check-schema:
cd flowkit && go run ./cmd/flow-schema/flow-schema.go --verify=true ./schema.json

.PHONY: check-tidy
check-tidy:
go mod tidy
cd flowkit; go mod tidy

.PHONY: generate-schema
generate-schema:
cd flowkit && go run ./cmd/flow-schema/flow-schema.go ./schema.json

.PHONY: generate
generate: install-tools
cd flowkit; \
go generate ./...
go generate ./...
2 changes: 1 addition & 1 deletion cmd/flow/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ func main() {
if outputFlag != "json" {

width := 80
url := "https://developers.flow.com/build/cadence-migration-guide"
url := "https://cadence-lang.org/docs/cadence_migration_guide"

// Function to center text within a given width
centerText := func(text string, width int) string {
Expand Down
285 changes: 0 additions & 285 deletions flowkit/CHANGELOG.md

This file was deleted.

17 changes: 2 additions & 15 deletions flowkit/README.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,3 @@
## Flowkit Package Design
Flowkit is a core package used by the CLI commands. It features APIs for interacting with the Flow network
in the context of flow.json configuration values. Flowkit is defined by the [interface here](services.go).

Flowkit contains multiple subpackages, the most important ones are:
- **config**: parsing and storing of flow.json values, as well as validation,
- **gateway**: implementation of Flow AN methods, uses emulator as well as Go SDK to communicate with ANs,
- **project**: stateful operations on top of flow.json, which allows resolving imports in contracts used in deployments

It is important we define clear boundaries between flowkit and other CLI packages. If we are in doubt where certain
methods should be implemented we must ask ourselves if the method provides value for any other consumers of the
pacakge or only provides utility for CLI usage, if it's only providing utility for CLI then it should be added inside
the internal package, instead of flowkit. If in doubt better to add things to internal package and then move to flowkit
if such need is identified.

## Flowkit

Note: This module has been migrated to github.com/onflow/flowkit. The latest supported version is v1.13.0. Please use the new module github.com/onflow/flowkit instead for any future updates. Version v1.13.0 is equivalent to version v1.13.0 on the new module.
Loading

0 comments on commit 752eb7b

Please sign in to comment.