Skip to content

Commit cd1acd2

Browse files
committed
chore: use pnpm for builds
Conflict Missing dependency
1 parent 3ab0dbb commit cd1acd2

25 files changed

+25725
-41269
lines changed

.devcontainer/server/container-start-backend.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,9 @@ cd "${IMMICH_WORKSPACE}/server" || (
1010
exit 1
1111
)
1212

13+
CI=1 pnpm install
1314
while true; do
14-
run_cmd node ./node_modules/.bin/nest start --debug "0.0.0.0:9230" --watch
15+
run_cmd pnpm exec nest start --debug "0.0.0.0:9230" --watch
1516
log "Nest API Server crashed with exit code $?. Respawning in 3s ..."
1617
sleep 3
1718
done

.devcontainer/server/container-start-frontend.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ until curl --output /dev/null --silent --head --fail "http://127.0.0.1:${IMMICH_
1616
done
1717

1818
while true; do
19-
run_cmd node ./node_modules/.bin/vite dev --host 0.0.0.0 --port "${DEV_PORT}"
19+
run_cmd pnpm exec vite dev --host 0.0.0.0 --port "${DEV_PORT}"
2020
log "Web crashed with exit code $?. Respawning in 3s ..."
2121
sleep 3
2222
done

.github/package-lock.json

Lines changed: 0 additions & 28 deletions
This file was deleted.

.github/workflows/cli.yml

Lines changed: 16 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -33,21 +33,24 @@ jobs:
3333
with:
3434
persist-credentials: false
3535

36-
# Setup .npmrc file to publish to npm
37-
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
36+
- name: Setup pnpm
37+
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
38+
39+
- name: Setup Node
40+
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
3841
with:
39-
node-version-file: './cli/.nvmrc'
42+
node-version-file: './server/.nvmrc'
4043
registry-url: 'https://registry.npmjs.org'
41-
cache: 'npm'
42-
cache-dependency-path: '**/package-lock.json'
43-
44-
- name: Prepare SDK
45-
run: npm ci --prefix ../open-api/typescript-sdk/
46-
- name: Build SDK
47-
run: npm run build --prefix ../open-api/typescript-sdk/
48-
- run: npm ci
49-
- run: npm run build
50-
- run: npm publish
44+
cache: 'pnpm'
45+
cache-dependency-path: '**/pnpm-lock.yaml'
46+
47+
- name: Setup typescript-sdk
48+
run: pnpm install && pnpm run build
49+
working-directory: ./open-api/typescript-sdk
50+
51+
- run: pnpm install --frozen-lockfile
52+
- run: pnpm build
53+
- run: pnpm publish
5154
if: ${{ github.event_name == 'release' }}
5255
env:
5356
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

.github/workflows/docs-build.yml

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -53,21 +53,24 @@ jobs:
5353
with:
5454
persist-credentials: false
5555

56+
- name: Setup pnpm
57+
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
58+
5659
- name: Setup Node
5760
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
5861
with:
59-
node-version-file: './docs/.nvmrc'
60-
cache: 'npm'
61-
cache-dependency-path: '**/package-lock.json'
62+
node-version-file: './cli/.nvmrc'
63+
cache: 'pnpm'
64+
cache-dependency-path: '**/pnpm-lock.yaml'
6265

63-
- name: Run npm install
64-
run: npm ci
66+
- name: Run install
67+
run: pnpm install
6568

6669
- name: Check formatting
67-
run: npm run format
70+
run: pnpm format
6871

6972
- name: Run build
70-
run: npm run build
73+
run: pnpm build
7174

7275
- name: Upload build output
7376
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2

.github/workflows/fix-format.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ jobs:
3333
with:
3434
node-version-file: './server/.nvmrc'
3535
cache: 'npm'
36-
cache-dependency-path: '**/package-lock.json'
36+
cache-dependency-path: '**/pnpm-lock.yaml'
3737

3838
- name: Fix formatting
3939
run: make install-all && make format-all

.github/workflows/sdk.yml

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,18 +20,21 @@ jobs:
2020
with:
2121
persist-credentials: false
2222

23+
- name: Setup pnpm
24+
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
25+
2326
# Setup .npmrc file to publish to npm
2427
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
2528
with:
2629
node-version-file: './open-api/typescript-sdk/.nvmrc'
2730
registry-url: 'https://registry.npmjs.org'
28-
cache: 'npm'
29-
cache-dependency-path: '**/package-lock.json'
31+
cache: 'pnpm'
32+
cache-dependency-path: '**/pnpm-lock.yaml'
3033
- name: Install deps
31-
run: npm ci
34+
run: pnpm install --frozen-lockfile
3235
- name: Build
33-
run: npm run build
36+
run: pnpm build
3437
- name: Publish
35-
run: npm publish
38+
run: pnpm publish
3639
env:
3740
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

0 commit comments

Comments
 (0)