Skip to content

Commit

Permalink
Merge pull request #145 from leonyi4/dev
Browse files Browse the repository at this point in the history
Added Devcontainer config file
  • Loading branch information
tomsch420 authored Apr 22, 2024
2 parents 5b88866 + 7c861c8 commit 0fa34c9
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 0 deletions.
15 changes: 15 additions & 0 deletions .devcontainer/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# How to use Dev container

- Install Docker and the 'Devcontainer' extension in VSCode

- Clone the repository and open the folder in VSCode

- Use `Ctrl/Cmd + Shift + P` to open the command palette

- Select 'Dev containers: Rebuild and Reopen in Container' Option

- Wait for the container to finish setting up

- Type this command into the terminal `roslaunch pycram ik_and_description.launch` to start roscore

- Note: Bullet world needs a display to be connected; the render mode needs to be set to direct when running on GitHub codespaces or on WindowOS; Otherwise, the kernel will crash
23 changes: 23 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"name": "PyCRAM vscode devcontainer",
"image": "pycram/pycram:dev",
"features": {
"ghcr.io/devcontainers/features/git:1": {},
"ghcr.io/devcontainers/features/sshd:1": {}
},
"postStartCommand": {
"pip": "pip3 install ipykernel pyjpt",
"git": "git config --global --add safe.directory '*'",
"source setup": "./.devcontainer/script.sh"
},
"customizations": {
"vscode": {
"extensions": [
"ms-python.python",
"ms-python.vscode-pylance",
"ms-toolsai.jupyter",
"esbenp.prettier-vscode"
]
}
}
}
7 changes: 7 additions & 0 deletions .devcontainer/script.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/bash

set -e

source /opt/ros/overlay_ws/devel/setup.bash

exec "$@"

0 comments on commit 0fa34c9

Please sign in to comment.