Skip to content

Commit

Permalink
update: README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
a5chin committed Aug 26, 2024
1 parent f775cf2 commit 7b46b18
Showing 1 changed file with 11 additions and 14 deletions.
25 changes: 11 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,21 @@
# VSCode Dev Container: Python Development with Rye, uv, and Ruff
# VSCode Dev Container: Python Development with uv and Ruff

<div align="center">

[![Rye](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/rye/main/artwork/badge.json)](https://github.com/astral-sh/rye)
[![uv](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/uv/main/assets/badge/v0.json)](https://github.com/astral-sh/uv)
[![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)

[![Versions](https://img.shields.io/badge/python-3.9%20|%203.10%20|%203.11%20|%203.12%20-green.svg)](https://github.com/a5chin/python-rye)

[![Ruff](https://github.com/a5chin/python-rye/actions/workflows/ruff.yml/badge.svg)](https://github.com/a5chin/python-rye/actions/workflows/ruff.yml)
[![test](https://github.com/a5chin/python-rye/actions/workflows/test.yml/badge.svg)](https://github.com/a5chin/python-rye/actions/workflows/test.yml)
[![Test](https://github.com/a5chin/python-rye/actions/workflows/test.yml/badge.svg)](https://github.com/a5chin/python-rye/actions/workflows/test.yml)
[![Docker](https://github.com/a5chin/python-rye/actions/workflows/docker.yml/badge.svg)](https://github.com/a5chin/python-rye/actions/workflows/docker.yml)

</div>

## Overview
This repository contains configurations to set up a Python development environment using VSCode's Dev Container feature.
The environment includes Rye, uv, and Ruff.
The environment includes uv, and Ruff.

![demo](assets/gif/ruff.gif)

Expand All @@ -27,7 +26,7 @@ Specifically, you can solve this problem by following the steps below.
2. Type `Developer: Reload Window` in the command palette to reload the window

### Contents
- [VSCode Dev Container: Python Development with Rye, uv, and Ruff](#vscode-dev-container-python-development-with-rye-uv-and-ruff)
- [VSCode Dev Container: Python Development with uv and Ruff](#vscode-dev-container-python-development-with-uv-and-ruff)
- [Overview](#overview)
- [Contents](#contents)
- [Branches](#branches)
Expand All @@ -42,6 +41,7 @@ Specifically, you can solve this problem by following the steps below.
## Branches
- [main](https://github.com/a5chin/python-rye/tree/main)
- [jupyter](https://github.com/a5chin/python-rye/tree/jupyter)
- [rye](https://github.com/a5chin/python-rye/tree/rye)(Archived)

## Dev Container
- `devcontainer.json`
Expand All @@ -64,9 +64,6 @@ Specifically, you can solve this problem by following the steps below.
- [usernamehw.errorlens](https://marketplace.visualstudio.com/items?itemName=usernamehw.errorlens)
- [yzhang.markdown-all-in-one](https://marketplace.visualstudio.com/items?itemName=yzhang.markdown-all-in-one)
- `Dockerfile`
- Rye
- `rye config --set-bool behavior.global-python=true`
- `rye config --set-bool behavior.use-uv=true`
- Only Dev dependencies
- `pre-commit`
- `pytest`
Expand Down Expand Up @@ -100,10 +97,10 @@ The `.pre-commit-config.yaml` file can contain scripts to be executed before com

```sh
# Python Formatter
rye run ruff format .
uv run ruff format .

# Python Linter
rye run ruff check . --fix
uv run ruff check . --fix

# Docker Linter
hodolint Dockerfile
Expand All @@ -116,13 +113,13 @@ Only sync based on the production lockfile (`requirements.lock`) instead of the

```sh
# Install also include develop dependencies
rye sync
uv sync

# If you do not want dev dependencies to be installed
rye sync --no-dev
uv sync --no-dev

# Use the add command to add dependencies to your project
rye add {libraries}
uv add {libraries}
```

### The structure of this repository
Expand All @@ -134,7 +131,7 @@ rye add {libraries}
├── Dockerfile
├── .github
│ ├── actions
│ │ └── setup-python-with-rye
│ │ └── setup-python-with-uv
│ │ └── action.yml
│ ├── dependabot.yml
│ └── workflows
Expand Down

0 comments on commit 7b46b18

Please sign in to comment.