Skip to content

Commit

Permalink
chore: remove yarn from flake
Browse files Browse the repository at this point in the history
  • Loading branch information
bodymindarts committed Oct 27, 2023
1 parent dcb1495 commit 14c3489
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 41 deletions.
48 changes: 24 additions & 24 deletions core/api/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,23 +10,23 @@ update-price-history:
docker compose run price-history node servers/history/cron.js

start-main:
. ./.env && yarn tsnd --respawn --files -r tsconfig-paths/register -r src/services/tracing.ts \
src/servers/graphql-main-server.ts | yarn pino-pretty -c -l
. ./.env && pnpm tsnd --respawn --files -r tsconfig-paths/register -r src/services/tracing.ts \
src/servers/graphql-main-server.ts | pnpm pino-pretty -c -l

start-main-fast:
yarn run watch-main | yarn pino-pretty -c -l
pnpm run watch-main | pnpm pino-pretty -c -l

start-trigger:
. ./.env && yarn tsnd --respawn --files -r tsconfig-paths/register -r src/services/tracing.ts \
src/servers/trigger.ts | yarn pino-pretty -c -l
. ./.env && pnpm tsnd --respawn --files -r tsconfig-paths/register -r src/services/tracing.ts \
src/servers/trigger.ts | pnpm pino-pretty -c -l

start-cron: start-deps
. ./.env && yarn tsnd --files -r tsconfig-paths/register -r src/services/tracing.ts \
src/servers/cron.ts | yarn pino-pretty -c -l
. ./.env && pnpm tsnd --files -r tsconfig-paths/register -r src/services/tracing.ts \
src/servers/cron.ts | pnpm pino-pretty -c -l

start-ws:
. ./.env && yarn tsnd --respawn --files -r tsconfig-paths/register -r src/services/tracing.ts \
src/servers/ws-server.ts | yarn pino-pretty -c -l
. ./.env && pnpm tsnd --respawn --files -r tsconfig-paths/register -r src/services/tracing.ts \
src/servers/ws-server.ts | pnpm pino-pretty -c -l

start-loopd:
./dev/bin/start-loopd.sh
Expand All @@ -44,11 +44,11 @@ start-ws-ci:
node dist/servers/ws-server.js

exporter: start-deps
. ./.env && yarn tsnd --respawn --files -r tsconfig-paths/register -r src/services/tracing.ts \
src/servers/exporter.ts | yarn pino-pretty -c -l
. ./.env && pnpm tsnd --respawn --files -r tsconfig-paths/register -r src/services/tracing.ts \
src/servers/exporter.ts | pnpm pino-pretty -c -l

watch:
yarn nodemon -V -e ts,graphql -w ./src -x make start
pnpm nodemon -V -e ts,graphql -w ./src -x make start

clean-deps:
docker compose down -t 3
Expand All @@ -64,7 +64,7 @@ test-migrate:
docker compose -f docker-compose.yml up mongodb-migrate --exit-code-from mongodb-migrate

unit:
yarn test:unit
pnpm run test:unit

watch-unit:
$(BIN_DIR)/jest --config ./test/unit/jest.config.js --clearCache
Expand All @@ -77,27 +77,27 @@ del-containers:
docker compose rm -sfv

legacy-integration:
yarn build && \
yarn test:legacy-integration
pnpm run build && \
pnpm run test:legacy-integration

reset-legacy-integration: reset-deps-integration legacy-integration

integration:
yarn build && \
yarn test:integration
pnpm run build && \
pnpm run test:integration

reset-integration: reset-deps-integration integration

bats:
yarn build && \
pnpm run build && \
bats -t test/bats

reset-bats: reset-deps bats

execute-bats-from-within-container:
git config --global --add safe.directory /repo # otherwise bats complains
yarn install && \
yarn build && \
pnpm install --frozen-lockfile && \
pnpm run build && \
bats -t test/bats

integration-in-ci:
Expand All @@ -107,7 +107,7 @@ integration-in-ci:
# NODE_OPTIONS line should be removed whenever we upgrade yarn.lock to see if
# heap allocation issue has been resolved in dependencies (fails at 2048).
execute-integration-from-within-container:
yarn install && \
pnpm run install --frozen-lockfile && \
SVIX_ENDPOINT= \
SVIX_SECRET= \
NODE_OPTIONS="--max-old-space-size=6144" \
Expand All @@ -120,7 +120,7 @@ unit-in-ci:
LOGLEVEL=warn $(BIN_DIR)/jest --config ./test/unit/jest.config.js --ci --bail --maxWorkers=50%

check-implicit:
yarn tsc-check-noimplicitany
pnpm run tsc-check-noimplicitany

check-code: check-implicit
pnpm run tsc-check
Expand Down Expand Up @@ -159,7 +159,7 @@ redis-flush:
docker-compose exec redis redis-cli FLUSHDB

codegen:
yarn write-sdl
pnpm run write-sdl

gen-test-jwt:
yarn gen-test-jwt
pnpm run gen-test-jwt
2 changes: 1 addition & 1 deletion core/api/dev/apollo-federation/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

To generate the supergraph you need to run:
```
$ yarn write-sdl
$ pnpm run write-sdl
```

which executes:
Expand Down
24 changes: 12 additions & 12 deletions core/api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,25 +8,25 @@
"eslint-check": "eslint src test --ext .ts",
"eslint-fix": "eslint src test --ext .ts --fix",
"build": "tsc -p tsconfig-build.json && cp -R src/services/price/protos dist/services/price/ && cp -R src/services/dealer-price/proto dist/services/dealer-price/ && cp -R src/services/loopd/protos dist/services/loopd/ && cp -R src/services/bria/proto dist/services/bria/ && tscpaths --silent -p tsconfig.json -s ./src -o ./dist",
"trigger": "yarn build && node dist/servers/trigger.js | pino-pretty -c -l",
"trigger": "pnpm run build && node dist/servers/trigger.js | pino-pretty -c -l",
"check:sdl": ". ../../.env && pnpm run write-sdl && if git diff --name-only | grep -q 'core/api/src/graphql/admin/schema.graphql'; then echo 'Error: core/api/src/graphql/admin/schema.graphql has changes, run `make codegen` and re-recommit' >&2; exit 1; fi && if git diff --name-only | grep -q 'core/api/src/graphql/public/schema.graphql'; then echo 'Error: core/api/src/graphql/public/schema.graphql has changes, run `make codegen` and re-recommit' >&2; exit 1; fi",
"write-sdl": "pnpm run build && node dist/servers/write-sdl.js write-sdl.yaml && rover supergraph compose --config dev/apollo-federation/supergraph-config.yaml --elv2-license accept > dev/apollo-federation/supergraph.graphql",
"ws": "yarn build && node dist/servers/ws-server.js | pino-pretty -c -l",
"watch": "nodemon -V -e ts,graphql -w ./src -x yarn run start",
"watch-trigger": "nodemon -V -e ts,graphql -w ./src -x yarn trigger",
"ws": "pnpm run build && node dist/servers/ws-server.js | pino-pretty -c -l",
"watch": "nodemon -V -e ts,graphql -w ./src -x pnpm run start",
"watch-trigger": "nodemon -V -e ts,graphql -w ./src -x pnpm run trigger",
"graphql-check": "curl -fsS https://raw.githubusercontent.com/GaloyMoney/galoy-mobile/main/app/graphql/generated.gql -o generated.gql && npx @graphql-inspector/cli validate ./generated.gql src/graphql/public/schema.graphql --apollo --noStrictFragments",
"cron": ". ../../.env && yarn build && node dist/servers/cron.js",
"exporter": "yarn build && node dist/servers/exporter.js",
"daily-notif": "yarn build && node dist/servers/daily-balance-notification.js",
"cron": ". ../../.env && pnpm run build && node dist/servers/cron.js",
"exporter": "pnpm run build && node dist/servers/exporter.js",
"daily-notif": "pnpm run build && node dist/servers/daily-balance-notification.js",
"test": "export JEST_JUNIT_OUTPUT_DIR=\"./artifacts\" && jest --ci --reporters=default --reporters=jest-junit",
"test:unit": ". ../../.env && LOGLEVEL=warn jest --config ./test/unit/jest.config.js --bail --verbose $TEST | yarn pino-pretty -c -l",
"test:legacy-integration": ". ../../.env && LOGLEVEL=warn jest --config ./test/legacy-integration/jest.config.js --bail --runInBand --verbose $TEST | yarn pino-pretty -c -l",
"test:integration": ". ../../.env && LOGLEVEL=warn jest --config ./test/integration/jest.config.js --bail --runInBand --verbose $TEST | yarn pino-pretty -c -l",
"test:unit": ". ../../.env && LOGLEVEL=warn jest --config ./test/unit/jest.config.js --bail --verbose $TEST | pnpm pino-pretty -c -l",
"test:legacy-integration": ". ../../.env && LOGLEVEL=warn jest --config ./test/legacy-integration/jest.config.js --bail --runInBand --verbose $TEST | pnpm pino-pretty -c -l",
"test:integration": ". ../../.env && LOGLEVEL=warn jest --config ./test/integration/jest.config.js --bail --runInBand --verbose $TEST | pnpm pino-pretty -c -l",
"build-docs": "npx spectaql spectaql-config.yml -1",
"fix-yaml": "prettier --write '**/*.(yaml|yml)'",
"check-yaml": "prettier --check '**/*.(yaml|yml)'",
"watch-main": ". ../../.env && nodemon -V -e ts,graphql -w ./src --exec yarn run start-main",
"start-main": ". ../../.env && yarn run build && node --inspect -r ./dist/services/tracing.js ./dist/servers/graphql-main-server.js",
"watch-main": ". ../../.env && nodemon -V -e ts,graphql -w ./src --exec pnpm run start-main",
"start-main": ". ../../.env && pnpm run build && node --inspect -r ./dist/services/tracing.js ./dist/servers/graphql-main-server.js",
"migrate-mongo-up": "migrate-mongo up -f './src/migrations/migrate-mongo-config.js'",
"gen-test-jwt": "ts-node dev/bin/gen-test-jwt.ts"
},
Expand Down
4 changes: 0 additions & 4 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@
(self: super: {
nodejs = super.nodejs_20;
pnpm = super.nodePackages.pnpm;
yarn = super.yarn.override {
nodejs = super.nodejs_20;
};
})
];
pkgs = import nixpkgs {inherit overlays system;};
Expand All @@ -47,7 +44,6 @@
envsubst
nodejs
tilt-pin.tilt
yarn
typescript
bats
postgresql
Expand Down

0 comments on commit 14c3489

Please sign in to comment.