Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
77 commits
Select commit Hold shift + click to select a range
ae9a9e3
feat: add avif encoding support; update dependencies and release prof…
Gunzinger Jun 23, 2025
d8d0d12
chore: finish MIT license cleanup, add notes about next TODOs
Gunzinger Jun 23, 2025
764a729
feat: add progress indicator (via indicatif rayon integration); add s…
Gunzinger Jun 23, 2025
7cfc75a
feat: add build.rs script to persist used dependency version numbers,…
Gunzinger Jun 23, 2025
39223db
feat: add dockerfiles (alpine and debian 12 / bookworm)
Gunzinger Jun 23, 2025
7382a56
chore: add gitignore file for examples folder (only track original im…
Gunzinger Jun 23, 2025
8f598ab
chore: update READMEs
Gunzinger Jun 23, 2025
923a882
chore: add GitHub action to publish docker container (WIP)
Gunzinger Jun 23, 2025
512aa14
chore: update workflow.yaml
Gunzinger Jun 23, 2025
f523590
chore: update workflow.yaml
Gunzinger Jun 23, 2025
59569e4
chore: update workflow.yaml
Gunzinger Jun 23, 2025
1d5d827
chore: update workflow.yaml
Gunzinger Jun 23, 2025
b673bdc
chore: update workflow.yaml
Gunzinger Jun 23, 2025
85dffd6
chore: update workflow.yaml
Gunzinger Jun 23, 2025
6ed8dfe
chore: try to build native binaries in github workflow.yaml
Gunzinger Jun 23, 2025
9373297
chore: try to fix native binaries build in github workflow.yaml
Gunzinger Jun 23, 2025
bc41b79
chore: try to fix native binaries build in github workflow.yaml
Gunzinger Jun 23, 2025
0b9e297
chore: fix native binaries build in github workflow.yaml
Gunzinger Jun 23, 2025
89814a8
chore: fix native binaries build in github workflow.yaml
Gunzinger Jun 23, 2025
a8be05c
chore: fix typo, add version to sha256 files in github workflow.yaml
Gunzinger Jun 23, 2025
cf564f6
chore: create release in workflow (needed to upload assets)
Gunzinger Jun 23, 2025
5711b28
chore: add dependabot.yml configuration (cargo, docker, github action…
Gunzinger Jun 24, 2025
d29b276
chore: update READMEs
Gunzinger Jun 24, 2025
75b587d
fix: modify package include path in Cargo.toml; add cargo crate publi…
Gunzinger Jun 24, 2025
e34bcd6
fix: adjust cargo crate publishing step
Gunzinger Jun 24, 2025
5b8bc56
fix: adjust cargo crate publishing step
Gunzinger Jun 24, 2025
4f3e02c
fix: specify indicatif dependency version
Gunzinger Jun 24, 2025
7e4d32c
chore: update READMEs with binary release and docker information + re…
Gunzinger Jun 24, 2025
4276e4c
chore: adjust WORKDIR in Dockerfiles to clear up usage
Gunzinger Jun 24, 2025
3074ec4
chore: improve formatting message for file deleting command
Gunzinger Jun 24, 2025
f6da7db
chore: update Cargo.toml links for homepage / repository to point to …
Gunzinger Jun 24, 2025
deba566
feat: ability to interrupt batch processing (stop queueing new jobs a…
Gunzinger Jun 26, 2025
d91224b
chore: update README.md
Gunzinger Jun 26, 2025
554f90c
chore: add README.md push to docker hub action to GitHub workflow.yaml
Gunzinger Jun 26, 2025
d9013e3
feat: add png(image), webp(image, losless) and jpeg(mozjpeg; UNSTABLE…
Gunzinger Jun 27, 2025
0c45525
chore: fix variable usage in REAMDE.md to docker hub push step in wor…
Gunzinger Jun 27, 2025
cdb5e45
feat: use upx to pack the generated executables to minimize size; cha…
Gunzinger Jun 28, 2025
5efdf6b
chore(deps): bump indicatif from 0.17.11 to 0.17.12
dependabot[bot] Jul 1, 2025
7581fdc
Merge pull request #1 from Gunzinger/dependabot/cargo/indicatif-0.17.12
Gunzinger Jul 2, 2025
38b753b
chore: update readme :)
Gunzinger Jul 3, 2025
8bda74a
chore: update readme :)
Gunzinger Jul 3, 2025
9f1376a
Merge branch 'main' of https://github.com/Gunzinger/imgc-rs
Gunzinger Jul 3, 2025
b63324f
chore: update readme again :)
Gunzinger Jul 3, 2025
4ea0dd7
chore(deps): bump rgb from 0.8.50 to 0.8.51
dependabot[bot] Jul 7, 2025
fde8b0d
chore(deps): bump indicatif from 0.17.12 to 0.18.0
dependabot[bot] Jul 7, 2025
84c7694
chore(deps): bump clap from 4.5.40 to 4.5.41
dependabot[bot] Jul 10, 2025
257fb63
chore(deps): bump cargo_metadata from 0.20.0 to 0.21.0
dependabot[bot] Jul 11, 2025
1a7bc0d
Merge pull request #3 from Gunzinger/dependabot/cargo/indicatif-0.18.0
Gunzinger Jul 11, 2025
8b023f0
Merge pull request #4 from Gunzinger/dependabot/cargo/clap-4.5.41
Gunzinger Jul 11, 2025
b2dd61c
Merge pull request #5 from Gunzinger/dependabot/cargo/cargo_metadata-…
Gunzinger Jul 11, 2025
b55e614
Merge branch 'main' into dependabot/cargo/rgb-0.8.51
Gunzinger Jul 11, 2025
6d8d19f
Merge pull request #2 from Gunzinger/dependabot/cargo/rgb-0.8.51
Gunzinger Jul 11, 2025
90396c8
fix: revert clap update, restore cli interface to documented state an…
Gunzinger Oct 27, 2025
9081715
feat: move to x86-64-v3 cpu by default (avx2) to improve efficiency a…
Gunzinger Oct 27, 2025
a9b1c3c
chore: update debian base in dockerfiles (bookworm -> trixie)
Gunzinger Oct 27, 2025
4798d79
chore: try a matrix release pipeline for different target-cpu configu…
Gunzinger Oct 27, 2025
fc9632b
fix: remove erronous x86-64v3 target-cpu
Gunzinger Oct 27, 2025
bb92cd9
fix: move cargo publish below nasm installation...; chore: update act…
Gunzinger Oct 27, 2025
eb4b504
fix: use right secret for crates.io token
Gunzinger Oct 27, 2025
7f0caa2
fix: fix binary versioning
Gunzinger Oct 27, 2025
4f79425
fix: create directory before trying to move stuff into it...
Gunzinger Oct 27, 2025
df2fe4c
fix: update README.md
Gunzinger Oct 27, 2025
36c0f8e
fix: detect and move imposter PNGs (png data in a file with another e…
Gunzinger Oct 27, 2025
5b62059
feat: handle imposter pngs automatically (retry as png); add jpeg-dec…
Gunzinger Oct 27, 2025
334d5b3
feat: output path handling improvements, now replaces the fixed input…
Gunzinger Oct 28, 2025
0b919c1
fix: stop parsing the entire file (twice) for path collection (remove…
Gunzinger Oct 28, 2025
4be8f3d
chore: remove debug message
Gunzinger Oct 28, 2025
c9fbe2e
chore: try to improve error handling for encoders
Gunzinger Oct 28, 2025
0f6bc47
fix: implement webp encode support for luma(a)8 images by casting the…
Gunzinger Oct 28, 2025
b69cb2f
fix: make reading images more robust by retrying with guessed format …
Gunzinger Oct 28, 2025
8d7ec76
fix: ensure lexicographical processing ordering; make reading images …
Gunzinger Oct 28, 2025
bc2e9f5
chore: move RUSTFLAGS env var declaration into job so that it is pick…
Gunzinger Oct 28, 2025
ef1ebee
chore: add switch to reverse the processing order
Gunzinger Oct 29, 2025
4637513
chore: update output behavior; handle progress bar state clean when r…
Gunzinger Oct 29, 2025
1dd6b93
chore: fix return path for discard_if_larget_than_input hitting files…
Gunzinger Oct 29, 2025
aac81d2
chore: update dependencies; ensure latest ravif version is used in en…
Gunzinger Jan 30, 2026
0ea3185
feat: enable decoding/loading of huge input images (remove artificial…
Gunzinger Feb 7, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .cargo/config.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[build]
rustflags = [
"-C", "target-cpu=x86-64-v3", # intel haswell / amd zen and later; avx2
# see: rustc --print target-cpus ; e.g. x86-64, x86-64-v3, x86-64-v4, znver3, znver5
# see: https://en.wikipedia.org/wiki/X86-64#Microarchitecture_levels
]
3 changes: 3 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
docs/
examples/
target/
24 changes: 24 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
version: 2
updates:
# Rust configuration
- package-ecosystem: "cargo"
# Ingests Cargo.toml
directory: "/"
schedule:
interval: "daily"

# Enable version updates for Docker
- package-ecosystem: "docker"
# Look for a `Dockerfile` in the `root` directory
directory: "/"
# Check for updates once a week
schedule:
interval: "weekly"

# Enable version updates for GitHub Actions
- package-ecosystem: "github-actions"
# Workflow files stored in the default location of `.github/workflows`
# You don't need to specify `/.github/workflows` for `directory`. You can use `directory: "/"`.
directory: "/"
schedule:
interval: "weekly"
147 changes: 147 additions & 0 deletions .github/workflows/workflow.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,147 @@
name: imgc-rs release pipeline
on:
push:
tags:
- 'v*.*.*'

env:
IMAGE_NAME: ${{ secrets.DOCKER_USERNAME }}/imgc-rs
BASE_CPU: x86-64-v3 # docker image and suffixless-binary use this as the target-cpu type

jobs:
create_release:
runs-on: ubuntu-latest
outputs:
release_id: ${{ steps.gh_release.outputs.id }}
release_upload_url: ${{ steps.gh_release.outputs.upload_url }}
steps:
- name: Checkout code
uses: actions/checkout@v6

# Create GitHub Release
- name: Create GitHub Release
id: gh_release
uses: softprops/action-gh-release@v2
with:
name: Release ${{ github.ref_name }}
tag_name: ${{ github.ref_name }}
draft: false
prerelease: false

build_binaries:
needs: create_release
runs-on: ubuntu-latest
strategy:
matrix:
cpu_target: [x86-64-v3, x86-64-v4, znver3, znver5]
name: Build binaries for ${{ matrix.cpu_target }}
env:
RUSTFLAGS: "-C target-cpu=${{ matrix.cpu_target }}"
steps:
- name: Checkout code
uses: actions/checkout@v6

# Extract version from the Git tag (strip leading 'v')
- name: Set version from tag
id: version
run: |
echo "VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_ENV

- name: Set Cargo.toml version
shell: bash
run: |
sed -i "s/0\\.0\\.0-git/${VERSION}/" Cargo.toml
head -n 5 Cargo.toml
sed -i "s/0\\.0\\.0-git/${VERSION}/" Cargo.lock
grep -i -C 5 "imgc" Cargo.lock

- name: Install Linux and Windows Cross Compilers
run: sudo apt-get install --yes --no-install-recommends musl-tools gcc-mingw-w64-x86-64-win32 nasm upx-ucl

- name: Install rustup targets
run: rustup target add x86_64-unknown-linux-musl x86_64-pc-windows-gnu

# rust package / target cache
- uses: Swatinem/rust-cache@v2

# Cargo publish (once!)
- name: Cargo publish crate
if: ${{ matrix.cpu_target == env.BASE_CPU }}
run: cargo publish --allow-dirty
env:
CARGO_REGISTRY_TOKEN: ${{ secrets.CRATES_IO_API_TOKEN }}

- name: Build binaries
shell: bash
run: |
echo "Building for CPU: ${{ matrix.cpu_target }}"

if [ "${{ matrix.cpu_target }}" == "${BASE_CPU}" ]; then
SUFFIX=""
else
SUFFIX="-${{ matrix.cpu_target }}"
fi
BIN_LINUX="imgc-${VERSION}${SUFFIX}"
BIN_WIN="imgc-${VERSION}${SUFFIX}.exe"

cargo build --release --target x86_64-unknown-linux-musl --target x86_64-pc-windows-gnu
mkdir -p current_release

# pack linux binary
cp target/x86_64-unknown-linux-musl/release/imgc current_release/${BIN_LINUX}
upx --best --ultra-brute current_release/${BIN_LINUX}
shasum -a 256 current_release/${BIN_LINUX} > current_release/${BIN_LINUX}.sha256

# pack windows binary
cp target/x86_64-pc-windows-gnu/release/imgc.exe current_release/${BIN_WIN}
upx --best --ultra-brute current_release/${BIN_WIN}
shasum -a 256 current_release/${BIN_WIN} > current_release/${BIN_WIN}.sha256

- name: Upload binaries to GitHub Release
uses: softprops/action-gh-release@v2
with:
name: Release ${{ github.ref_name }}
tag_name: ${{ github.ref_name }}
files: current_release/*

publish_docker:
needs: create_release
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v6

- name: Log in to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Generate Docker metadata
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.IMAGE_NAME }}
env:
DOCKER_METADATA_ANNOTATIONS_LEVELS: manifest,index

- name: Build and Push Docker image
uses: docker/build-push-action@v6
with:
context: .
file: Dockerfile
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}

- name: Push README.md to Dockerhub
uses: peter-evans/dockerhub-description@v5
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
repository: ${{ env.IMAGE_NAME }}
short-description: 'imgc-rs, configurable and efficient batch image converter'
enable-url-completion: true
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/target
.tmp
.DS_Store

.idea/
upx/

data/

# debug/repro screenshots
debug*/
Loading