Skip to content

Commit e44e4ca

Browse files
committed
Merge branch 'main' into config-cleanup
2 parents 1a9b692 + 0fd915b commit e44e4ca

File tree

10 files changed

+1609
-5682
lines changed

10 files changed

+1609
-5682
lines changed

.github/actions/setup-env/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ description: "Setup development environment"
33

44
inputs:
55
environment:
6-
default: "default"
6+
default: "base-py310"
77
description:
8-
"Pixi environment to activate. Examples include 'default', 'dev-all-py312'"
8+
"Pixi environment to activate. Examples include 'base-py310' or 'all-py313'."
99

1010
runs:
1111
using: composite

.github/workflows/docker.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,6 @@ jobs:
3838

3939
- name: Setup environment
4040
uses: ./.github/actions/setup-env
41-
with:
42-
environment: "dev-py310"
4341

4442
- name: Set up QEMU
4543
uses: docker/setup-qemu-action@v3

.github/workflows/lint.yml

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,9 @@ jobs:
1818

1919
- name: Setup environment
2020
uses: ./.github/actions/setup-env
21-
with:
22-
environment: "dev-py310"
2321

2422
- name: Test optional dependencies
25-
run: |
26-
pixi run optional-dependencies
23+
run: pixi run optional-dependencies
2724

2825
format:
2926
runs-on: ubuntu-latest
@@ -36,8 +33,6 @@ jobs:
3633

3734
- name: Setup environment
3835
uses: ./.github/actions/setup-env
39-
with:
40-
environment: "dev-py310"
4136

4237
- uses: actions/cache@v4
4338
with:
@@ -64,7 +59,7 @@ jobs:
6459
- name: Setup environment
6560
uses: ./.github/actions/setup-env
6661
with:
67-
environment: "dev-all-py310"
62+
environment: all-py310
6863

6964
- name: Run type checks
7065
run: pixi run types

.github/workflows/release.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,6 @@ jobs:
2020

2121
- name: Setup environment
2222
uses: ./.github/actions/setup-env
23-
with:
24-
environment: "dev-py310"
2523

2624
- name: Build dists
2725
run: pixi run build

.github/workflows/test.yml

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@ jobs:
2424

2525
- name: Setup environment
2626
uses: ./.github/actions/setup-env
27-
with:
28-
environment: "dev-py310"
2927

3028
- name: Check if all public packages are importable
3129
run: python tests/test_importable.py
@@ -37,14 +35,14 @@ jobs:
3735
- ubuntu-latest
3836
- windows-latest
3937
- macos-latest
40-
environment: ["dev-all-py310"]
38+
environment: ["all-py310"]
4139
include:
4240
- os: ubuntu-latest
43-
environment: "dev-all-py311"
41+
environment: "all-py311"
4442
- os: ubuntu-latest
45-
environment: "dev-all-py312"
43+
environment: "all-py312"
4644
- os: ubuntu-latest
47-
environment: "dev-all-py313"
45+
environment: "all-py313"
4846

4947
fail-fast: false
5048

.readthedocs.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,11 @@ build:
3131
PIXI_VERSION=v0.45.0 bash
3232
# We call the full path of the executable /home/docs/.pixi/bin/pixi because
3333
# the installation process does not add the executable to the $PATH
34-
- /home/docs/.pixi/bin/pixi install --frozen --environment dev-all-py312
34+
- /home/docs/.pixi/bin/pixi install --frozen --environment all-py310
3535
post_install:
3636
- git update-index --really-refresh || true
3737
build:
3838
html:
3939
- mkdir --parents $READTHEDOCS_OUTPUT/html/
40-
- /home/docs/.pixi/bin/pixi run --frozen --environment dev-all-py312 mkdocs
41-
build --site-dir $READTHEDOCS_OUTPUT/html/
40+
- /home/docs/.pixi/bin/pixi run --frozen --environment all-py310 mkdocs build
41+
--site-dir $READTHEDOCS_OUTPUT/html/

Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ COPY pyproject.toml pixi.lock .
1515
# since setuptools-scm cannot infer the version
1616
RUN echo '[tool.setuptools.package-data]\n"*" = ["*"]' >> pyproject.toml
1717
ARG SETUPTOOLS_SCM_PRETEND_VERSION_FOR_RAGNA
18-
ARG ENVIRONMENT="default-all-py313"
18+
ARG ENVIRONMENT="all-docker"
1919

2020
RUN <<EOF
2121
pixi shell-hook --frozen --environment $ENVIRONMENT --shell bash > /shell-hook.sh;
@@ -33,7 +33,7 @@ USER bodil
3333

3434
WORKDIR /var/ragna
3535

36-
COPY --from=build --chown=bodil:bodil /var/ragna/.pixi/envs/default-all-py313 /var/ragna/.pixi/envs/default-all-py313
36+
COPY --from=build --chown=bodil:bodil /var/ragna/.pixi/envs/${ENVIRONMENT} /var/ragna/.pixi/envs/${ENVIRONMENT}
3737
COPY --from=build --chown=bodil:bodil --chmod=0755 /entrypoint.sh /entrypoint.sh
3838
COPY --from=build --chown=bodil:bodil /var/ragna/ragna /var/ragna/ragna
3939

docs/community/contribute.md

Lines changed: 12 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -29,30 +29,26 @@ git clone https://github.com/<your-username>/ragna.git
2929

3030
### Set up development environment and run Ragna
3131

32-
We use [Pixi](https://pixi.sh/dev/) to manage development environments with Ragna.
33-
34-
Ragna has three main development environments: `dev-all-py310`, `dev-all-py311`, and
35-
`dev-all-py312`, which use Python 3.10, 3.11, and 3.12, respectively. The environment
36-
`dev-all` is the same as `dev-all-py310`. The environment `dev-all` is used as an
37-
example in the sections below, but you can use any of the three Python versions you
38-
like.
32+
We use [Pixi](https://pixi.sh/dev/) to manage development environments with Ragna. The
33+
main development environment is `all-py310`, which should be used for most use cases and
34+
is used in the sections below.
3935

4036
To install a development environment, run
4137

4238
```bash
43-
pixi install -e dev-all --frozen
39+
pixi install --environment all-py310 --frozen
4440
```
4541

4642
You can then run Ragna with
4743

4844
```bash
49-
pixi run -e dev-all ragna deploy
45+
pixi run --environment all-py310 ragna deploy
5046
```
5147

5248
You can verify that a development version of Ragna is correctly installed with
5349

5450
```bash
55-
pixi run -e dev-all ragna --version
51+
pixi run --environment all-py310 ragna --version
5652
# Ideal output: ragna <version-number> devXXXX from ...
5753
```
5854

@@ -75,7 +71,7 @@ on each pull request.
7571
You can run Ragna tests with
7672

7773
```bash
78-
pixi run -e dev-all test
74+
pixi run --environment all-py310 test
7975
```
8076

8177
#### Formatting & Linting
@@ -84,21 +80,21 @@ To run the [Ruff code formatter and checker](https://docs.astral.sh/ruff/formatt
8480
well as other useful formatting and linting tools, you can use
8581

8682
```bash
87-
pixi run -e dev pre-commit
83+
pixi run --environment all-py310 pre-commit
8884
```
8985

9086
#### Type checking
9187

9288
You can check type annotations with [Mypy](https://mypy-lang.org/) using
9389

9490
```bash
95-
pixi run -e dev-all types
91+
pixi run --environment all-py310 types
9692
```
9793

9894
or
9995

10096
```bash
101-
pixi run -e dev-all mypy
97+
pixi run --environment all-py310 mypy
10298
```
10399

104100
#### All of the above
@@ -107,7 +103,7 @@ To run all the above checks using a single command as they would be run on the C
107103
can use
108104

109105
```bash
110-
pixi run -e dev-all ci
106+
pixi run ---environment all-py310 ci
111107
```
112108

113109
## Contribute documentation
@@ -127,13 +123,11 @@ To start a development build of the website that auto-refreshes on new changes,
127123
following from the project root:
128124

129125
```bash
130-
pixi run -e dev-all mkdocs serve
126+
pixi run --environment all-py310 mkdocs serve
131127
```
132128

133129
This serves the docs website at [http://127.0.0.1:8000](http://127.0.0.1:8000).
134130

135-
You must use a `dev-all*` environment to build the docs.
136-
137131
### View, add, or update images
138132

139133
Ragna tracks most image files with [`git-lfs`](https://git-lfs.com).

0 commit comments

Comments
 (0)