Skip to content

Commit 0b9a6db

Browse files
committed
build: optimize new baseline images with oxipng on commit
1 parent 732cf08 commit 0b9a6db

2 files changed

Lines changed: 10 additions & 0 deletions

File tree

.pre-commit-config.yaml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,12 @@ repos:
77
args: [--select=I001, --fix]
88
# Run the formatter.
99
- id: ruff-format
10+
- repo: local
11+
hooks:
12+
# Requires the oxipng binary on PATH:
13+
# brew install oxipng (or: cargo install oxipng)
14+
- id: oxipng
15+
name: optimize baseline images
16+
entry: oxipng -o 4 --strip safe
17+
language: system
18+
files: ^tests/baseline_images/.*\.png$

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,7 @@ Development version
138138

139139
```console
140140
$ pip install git+https://github.com/has2k1/plotnine.git
141+
$ brew install oxipng # Test image optimiser (OR `cargo install oxipng`)
141142
```
142143

143144
## Contributing

0 commit comments

Comments
 (0)