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

chore: update vscode devcontainer and fix tests in devcontainer #505

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from
Open
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
1 change: 0 additions & 1 deletion .devcontainer/Dockerfile

This file was deleted.

6 changes: 2 additions & 4 deletions .devcontainer/compose.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
services:
app:
build:
context: .
dockerfile: Dockerfile

image: mcr.microsoft.com/devcontainers/javascript-node:20

volumes:
- ../:/workspace:cached
- node_modules:/workspace/node_modules
Expand Down
2 changes: 1 addition & 1 deletion .devcontainer/devcontainer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
#───┘ URL └─────────────────────────────────────────────────────

# Final accessible URL seen by a user.
url: http://127.0.0.1:3000/
url: http://cherrypick.local/

# ONCE YOU HAVE STARTED THE INSTANCE, DO NOT CHANGE THE
# URL SETTINGS AFTER THAT!
Expand Down
3 changes: 2 additions & 1 deletion .devcontainer/init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,15 @@ set -xe

sudo chown node node_modules
sudo apt-get update
sudo apt-get -y install libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libnss3 libxss1 libasound2 libxtst6 xauth xvfb
sudo apt-get -y install ffmpeg libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libnss3 libxss1 libasound2 libxtst6 xauth xvfb
git config --global --add safe.directory /workspace
git submodule update --init
corepack install
corepack enable
pnpm config set store-dir /home/node/.local/share/pnpm/store
pnpm install --frozen-lockfile
cp .devcontainer/devcontainer.yml .config/default.yml
[ ! -L .config/test.yml ] && ln -s default.yml .config/test.yml
pnpm build
pnpm migrate
pnpm exec cypress install
17 changes: 17 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "launch",
"name": "CherryPick",
"skipFiles": [
"<node_internals>/**"
],
"program": "${workspaceFolder}/packages/backend/built/boot/entry.js"
}
]
}
3 changes: 2 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@
"editor.codeActionsOnSave": {
"source.fixAll": "explicit"
},
"editor.formatOnSave": false
"editor.formatOnSave": false,
"npm.packageManager": "pnpm"
}
16 changes: 16 additions & 0 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"version": "2.0.0",
"tasks": [
{
"type": "npm",
"script": "build",
"group": {
"kind": "build",
"isDefault": true
},
"problemMatcher": [],
"label": "pnpm: build",
"detail": "pnpm build-pre && pnpm -r build && pnpm build-assets"
}
]
}
Loading