Skip to content

Commit 912a90e

Browse files
authored
Merge pull request #5 from Geson-anko/fix/devcontainer-setup
feat: update Docker configuration and clean up .dockerignore
2 parents 6ef2f15 + fb1b466 commit 912a90e

File tree

5 files changed

+12
-186
lines changed

5 files changed

+12
-186
lines changed

.dockerignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Start by removing everything and add just the things we need
2+
*
3+
!src
4+
!CMakeLists.txt
5+
!include
6+
!cmake/

bindings/python/.devcontainer/Dockerfile

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,8 @@ FROM ubuntu:24.04
33
# Install uv
44
COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/
55
ENV UV_LINK_MODE=copy
6-
7-
RUN mkdir /workspace
8-
COPY . /workspace/
9-
WORKDIR /workspace/bindings/python
6+
# Shell completion
7+
RUN echo 'eval "$(uv generate-shell-completion bash)"' >> ~/.bashrc
108

119
ENV DEBIAN_FRONTEND=noninteractive
1210
RUN apt-get update && apt-get install -y --no-install-recommends \
@@ -22,9 +20,4 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
2220
make \
2321
pkg-config \
2422
git \
25-
&& rm -rf /var/lib/apt/lists/* \
26-
&& uv sync \
27-
# Shell completion
28-
&& echo 'eval "$(uv generate-shell-completion bash)"' >> ~/.bashrc \
29-
# Auto activate venv
30-
&& echo 'source /workspace/bindings/python/.venv/bin/activate' >> ~/.bashrc
23+
&& rm -rf /var/lib/apt/lists/*

bindings/python/.devcontainer/devcontainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
},
77
"privileged": true,
88
// Mount the root of the repository so that the C++ code can be built
9-
"workspaceMount": "source=inputtino-python-dev,target=/workspace,type=volume",
9+
"workspaceMount": "source=${localWorkspaceFolder}/../../,target=/workspace,type=bind",
1010
"workspaceFolder": "/workspace/bindings/python",
1111
"mounts": [
1212
"source=uv-cache,target=/root/.cache/uv,type=volume",

bindings/python/.dockerignore

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

bindings/python/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ help: ## Show help
33

44
clean: ## Clean autogenerated files
55
rm -rf dist
6+
rm -rf build
7+
rm -rf .venv
68
find . -type f -name "*.DS_Store" -ls -delete
79
find . | grep -E "(__pycache__|\.pyc|\.pyo)" | xargs rm -rf
810
find . | grep -E ".pytest_cache" | xargs rm -rf

0 commit comments

Comments
 (0)