Skip to content

Commit ee791b3

Browse files
committed
Build a conda package
1 parent 0960e88 commit ee791b3

File tree

4 files changed

+91
-2
lines changed

4 files changed

+91
-2
lines changed

.github/workflows/continuous-integration.yml

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -148,12 +148,32 @@ jobs:
148148
- name: Check LICENSE.txt in sdist
149149
run: tar -tvf dist/*.tar.gz | grep -q itables_for_dash/async-ITable.js.LICENSE.txt
150150

151+
# Build conda package
152+
- name: Set up Mambaforge
153+
uses: conda-incubator/setup-miniconda@v3
154+
with:
155+
miniforge-variant: Mambaforge
156+
miniforge-version: latest
157+
use-mamba: true
158+
auto-update-conda: true
159+
python-version: 3.11
160+
161+
- name: Install conda-build
162+
run: mamba install conda-build -y
163+
164+
- name: Build conda package
165+
run: |
166+
conda config --set anaconda_upload no
167+
conda build conda.recipe --output-folder conda-dist
168+
151169
# Upload the wheel as an artifact
152170
- name: Upload wheel artifact
153171
uses: actions/upload-artifact@v4
154172
with:
155-
name: itables-wheel
156-
path: dist/*.whl
173+
name: itables-wheel-and-conda-package
174+
path: |
175+
dist/*.whl
176+
conda-dist/**/*.tar.bz2
157177
158178
# Comment on PR with artifact link (only on PRs)
159179
- name: Comment with direct artifact link

.pre-commit-config.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ repos:
99
hooks:
1010
- id: check-json
1111
- id: check-yaml
12+
exclude: ^conda\.recipe/meta\.yaml$
1213
- id: end-of-file-fixer
1314
- id: trailing-whitespace
1415

conda.recipe/meta.yaml

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
{% set name = "itables" %}
2+
{% set version = environ.get('GIT_DESCRIBE_TAG', None) %}
3+
{% if version %}
4+
{% set version = version.lstrip('v') %}
5+
{% else %}
6+
{% set version = load_file_data('src/itables/version.py', 'r').split('=')[1].strip().strip('"\'') %}
7+
{% endif %}
8+
9+
package:
10+
name: {{ name|lower }}
11+
version: {{ version }}
12+
13+
source:
14+
path: ..
15+
16+
build:
17+
number: 0
18+
noarch: python
19+
script: {{ PYTHON }} -m pip install . -vv
20+
21+
requirements:
22+
host:
23+
- nodejs
24+
- python >=3.9
25+
- python-build
26+
- hatch-jupyter-builder
27+
- hatchling
28+
- pip
29+
run:
30+
- ipython
31+
- pandas
32+
- numpy
33+
- packaging
34+
- typing-extensions
35+
- python >=3.9
36+
37+
test:
38+
imports:
39+
- itables
40+
- itables.widget
41+
commands:
42+
- pip check
43+
- python -c "import itables; print(itables.__version__)"
44+
requires:
45+
- pip
46+
47+
about:
48+
home: https://github.com/mwouts/itables
49+
dev_url: https://github.com/mwouts/itables
50+
doc_url: https://mwouts.github.io/itables
51+
summary: Pandas and Polars DataFrames as Interactive DataTables
52+
license: MIT
53+
license_file:
54+
- LICENSE
55+
- src/itables/javascript/LICENSE_jquery.txt
56+
- src/itables/javascript/LICENSE_datatables-net.txt
57+
description: |
58+
Render Pandas and Polars DataFrames as interactive [DataTables](https://datatables.net/)
59+
that you can sort, paginate, scroll or filter. ITables works in Jupyter,
60+
VS Code, Google Colab, Quarto, Marimo, and in many application frameworks like
61+
Dash, Panel, Shiny, or Streamlit.

docs/changelog.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,13 @@
11
ITables ChangeLog
22
=================
33

4+
2.5.2 (2025-09-01)
5+
------------------
6+
7+
**Added**
8+
- A conda package is built (and attached) to each PR.
9+
10+
411
2.5.1 (2025-08-31)
512
------------------
613

0 commit comments

Comments
 (0)