Tool for converting `pixi update` diffs to markdown
Project description
pixi-diff-to-markdown
pixi-diff-to-markdown is a tool that generates markdown from a JSON diff that's generated by pixi update --json.
It reads from the standard input and writes to the standard output.
pixi update --no-install --json | pixi exec pixi-diff-to-markdown > diff.md
[!TIP] If you don't care about the environment being installed and only want to update the lockfile (for example in a CI pipeline), you can use
pixi update --json --no-installto generate the diff.
Example output:
| Dependency | Before | After | Change |
|---|---|---|---|
| new-package | 0.10.1 | Added | |
| removed-package | 0.10.1 | Removed | |
| bpy | 0.10.1 | 2.10.1 | Major Upgrade |
| polars | herads_0 | herads_1 | Only build string |
| python | 0.10.0 | 0.10.1 | Patch Upgrade |
[!TIP] The sorting of the tables is done by explicit/implicit, change type and alphabetically.
Installation
You can install pixi-diff-to-markdown using pip or pixi.
# via pixi
pixi global install pixi-diff-to-markdown
# via pip
pip install pixi-diff-to-markdown
Configuration
Depending on your use case, you may want to configure the output of pixi-diff-to-markdown.
You can do this by creating a configuration section in pixi.toml or pyproject.toml.
# defaults
[tool.pixi-diff-to-markdown]
merge-dependencies = "no" # or "split-explicit" when there are three or more environments / platforms
hide-tables = "auto"
max-expanded-rows = 10
change-type-column = true
explicit-column = false
package-type-column = false
create-links-for-packages = true
You can also override the configuration options by passing them as arguments to pixi-diff-to-markdown.
pixi update --json | pixi-diff-to-markdown --merge-dependencies=yes --explicit-column
merge-dependencies
Depending on the amount of environments and platforms you have in your pixi.toml, it might make sense to either merge all dependencies into one table, split them by explicit and implicit dependencies or split them by environment and platform.
For a large amount of environments and platforms, it is recommended to merge the dependencies into one table for deduplication.
merge-dependencies can be set to one of the following values:
no: Don't merge the dependencies, each environment will be displayed in their own table. Only recommended for a small amount of environments / platforms (example).yes: Merge all dependencies into one table and deduplicate them (example).split-explicit: Merge all dependencies into one table and deduplicate them but split the table into oneexplicitand oneimplicittable (example).
The default is no when there are less than three environments / platforms and split-explicit when there are three or more environments / platforms.
hide-tables
Whether to hide the tables in a collapsible object.
hide-tables can be set to one of the following values (defaults to auto):
no: Don't hide the tables (example).yes: Put the tables in collapsible objects (example).auto: Put the tables in collapsible objects if there are at mostmax-expanded-rowsrows in each table.
max-expanded-rows
The maximum amount of rows in a table before it is hidden.
Defaults to 10.
change-type-column
Whether to enable the Change column in the output (example true, example false).
explicit-column
Whether to enable the Explicit column in the output (example true, example false).
If a dependency is explicitly defined in pixi.toml, it will be marked as Explicit. Otherwise, it will be marked as Implicit.
If this is set to false, the Explicit column will be omitted and the explicitly defined dependencies will be marked as cursive.
package-type-column
Whether to enable the Package Type column in the output (example true, example false).
This column will show whether the dependency is a conda or pypi package.
create-links-for-packages
Whether to create links for packages from public channels (i.e., conda-forge or bioconda, etc.) or channels on prefix.dev (example).
Defaults to true.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pixi_diff_to_markdown-0.3.6.tar.gz.
File metadata
- Download URL: pixi_diff_to_markdown-0.3.6.tar.gz
- Upload date:
- Size: 412.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c2a27db5ff2546b5306c2c0c51f0986b533cd4b880f5d690d4225e42f6ec21fa
|
|
| MD5 |
ae9d35c6e2ebe01984ad5a340d531f7d
|
|
| BLAKE2b-256 |
f175ba2b6f31975ad195b145b463d835be8bd739f16256f7ca30641367862171
|
Provenance
The following attestation bundles were made for pixi_diff_to_markdown-0.3.6.tar.gz:
Publisher:
build.yml on pavelzw/pixi-diff-to-markdown
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pixi_diff_to_markdown-0.3.6.tar.gz -
Subject digest:
c2a27db5ff2546b5306c2c0c51f0986b533cd4b880f5d690d4225e42f6ec21fa - Sigstore transparency entry: 681467167
- Sigstore integration time:
-
Permalink:
pavelzw/pixi-diff-to-markdown@ff313dc23b66081822c6f515e3bcfaae869da58c -
Branch / Tag:
refs/heads/main - Owner: https://github.com/pavelzw
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
build.yml@ff313dc23b66081822c6f515e3bcfaae869da58c -
Trigger Event:
push
-
Statement type:
File details
Details for the file pixi_diff_to_markdown-0.3.6-py3-none-any.whl.
File metadata
- Download URL: pixi_diff_to_markdown-0.3.6-py3-none-any.whl
- Upload date:
- Size: 15.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7ededa346065bfc6969cfff29c716ee81af26e3b0d5746effa7149d7174df61e
|
|
| MD5 |
98dac1df96836ec1bc367bab4df1688f
|
|
| BLAKE2b-256 |
3dae19a508286572125feea63aa664bf7b4b72b8ace021212b94bd7a6b1e12dd
|
Provenance
The following attestation bundles were made for pixi_diff_to_markdown-0.3.6-py3-none-any.whl:
Publisher:
build.yml on pavelzw/pixi-diff-to-markdown
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pixi_diff_to_markdown-0.3.6-py3-none-any.whl -
Subject digest:
7ededa346065bfc6969cfff29c716ee81af26e3b0d5746effa7149d7174df61e - Sigstore transparency entry: 681467170
- Sigstore integration time:
-
Permalink:
pavelzw/pixi-diff-to-markdown@ff313dc23b66081822c6f515e3bcfaae869da58c -
Branch / Tag:
refs/heads/main - Owner: https://github.com/pavelzw
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
build.yml@ff313dc23b66081822c6f515e3bcfaae869da58c -
Trigger Event:
push
-
Statement type: