Skip to content

Commit 02e5a7f

Browse files
committed
Add Codespaces devcontainer
1 parent 98298d9 commit 02e5a7f

3 files changed

Lines changed: 35 additions & 0 deletions

File tree

.devcontainer/Dockerfile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
ARG UV_VERSION=0.11.16
2+
FROM ghcr.io/astral-sh/uv:${UV_VERSION} AS uv
3+
4+
FROM mcr.microsoft.com/devcontainers/python:3.12
5+
6+
COPY --from=uv /uv /uvx /usr/local/bin/

.devcontainer/devcontainer.json

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
{
2+
"name": "OpenDecree Python SDK",
3+
"build": {
4+
"dockerfile": "Dockerfile"
5+
},
6+
"postCreateCommand": "uv venv --python 3.12 .venv && uv pip install --python .venv/bin/python -e \"sdk[dev]\"",
7+
"remoteEnv": {
8+
"VIRTUAL_ENV": "${workspaceFolder}/.venv",
9+
"PATH": "${workspaceFolder}/.venv/bin:${containerEnv:PATH}"
10+
},
11+
"customizations": {
12+
"vscode": {
13+
"settings": {
14+
"python.defaultInterpreterPath": "${workspaceFolder}/.venv/bin/python",
15+
"python.testing.pytestArgs": [
16+
"sdk/tests"
17+
],
18+
"python.testing.pytestEnabled": true,
19+
"ruff.nativeServer": "on"
20+
},
21+
"extensions": [
22+
"ms-python.python",
23+
"ms-python.mypy-type-checker",
24+
"charliermarsh.ruff"
25+
]
26+
}
27+
}
28+
}

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
[![License](https://img.shields.io/github/license/opendecree/decree-python)](LICENSE)
88
[![Project Status: WIP](https://www.repostatus.org/badges/latest/wip.svg)](https://www.repostatus.org/#wip)
99
[![codecov](https://codecov.io/gh/opendecree/decree-python/graph/badge.svg)](https://codecov.io/gh/opendecree/decree-python)
10+
[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/opendecree/decree-python)
1011

1112
Python SDK for [OpenDecree](https://github.com/opendecree/decree) — schema-driven configuration management.
1213

0 commit comments

Comments
 (0)