diff --git a/.github/workflows/update.yml b/.github/workflows/update.yml index 3ddad24..5a73001 100644 --- a/.github/workflows/update.yml +++ b/.github/workflows/update.yml @@ -42,15 +42,15 @@ jobs: set -x # remove the symlinks - rm -f gen/sdp-go gen/sdp-js + rm -Rf gen/sdp-go gen/sdp-js # replace them with full checkouts - git clone https://${GIT_USER}@github.com/overmindtech/sdp-go.git gen/sdp-go - git clone https://${GIT_USER}@github.com/overmindtech/sdp-js.git gen/sdp-js + git clone https://${GIT_USER}@github.com/overmindtech/sdp-go.git gen/sdp-go.git + git clone https://${GIT_USER}@github.com/overmindtech/sdp-js.git gen/sdp-js.git # remove previously generated files - rm -Rf gen/sdp-go/*.pb.go gen/sdp-go/sdpconnect/*.connect.go - rm -Rf gen/sdp-js/src/__generated__/ + rm -Rf gen/sdp-go.git/*.pb.go gen/sdp-go/sdpconnect/*.connect.go + rm -Rf gen/sdp-js.git/src/__generated__/ # generate the code npx buf generate @@ -60,8 +60,9 @@ jobs: # add and commit the results for i in sdp-go sdp-js; do ( - cd gen/$i + cd gen/$i.git git pull + cp -av ../$i/* . git add -A git commit -m "Updated to SDP ${SDP_DESCRIBE}" || exit 0 diff --git a/README.md b/README.md index 36ab149..e555ad0 100644 --- a/README.md +++ b/README.md @@ -207,23 +207,4 @@ Sources that encountered errors will send errors on the `query.{uuid}` subject o ## Building -Install the Go dependencies: - -```shell -go install google.golang.org/protobuf/cmd/protoc-gen-go@latest -go install connectrpc.com/connect/cmd/protoc-gen-connect-go@latest -``` - -Install the Node dependencies: - -```shell -npm i -``` - -Run `buf` through `npx` to generate the stubs: - -```shell -npx buf generate -``` - -> Note: depending on your use case, symlink or checkout the `sdp-js` and `sdp-go` repositories into the `gen/` directory. See `sdp/.github/workflows/update.yml` for details. +See `sdp/.github/workflows/update.yml` for details. Previously this was easily done locally, but recent changes to buf broke the symlink method.