This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
This is a Node.js package that vendors the Perl ExifTool binary for non-Windows systems. It provides the ExifTool executable as an npm package, making it easily installable for Node.js projects that need to work with image metadata.
npm test- Run the test suite to verify ExifTool is working correctlynpm run prettier- Format test files using Prettiernpm run update-exiftool- Updates ExifTool from the official repository
ExifTool updates are fully automated via GitHub Actions:
- The
check-updatesworkflow runs weekly and creates PRs for new versions - To manually check for updates: trigger the workflow from GitHub Actions tab
- After merging an update PR: trigger the
releaseworkflow to publish to npm
Manual update process (if needed):
- Run
npm run update-exiftoolwhich executesupdate-exiftool.sh - The script will:
- Clone or update the ExifTool repository in the parent directory
- Copy the latest ExifTool files to
bin/ - Remove unnecessary files (tests, help files, Windows executables)
- Set the package version to match ExifTool's version with
-presuffix
- After committing changes, use the GitHub Actions release workflow to publish
Tests are written with Mocha and verify that:
- The vendored ExifTool binary can be executed
- Version output is correctly formatted
- No stderr output is produced during normal operation
Run tests with: npm test
The package is minimal:
index.js- Exports the path to the ExifTool binarybin/exiftool- The vendored ExifTool Perl script (not tracked in git)update-exiftool.sh- Script to update ExifTool from the official repository
Releases are automated via the GitHub Actions release workflow:
- Trigger the workflow manually from the Actions tab
- Optionally specify version increment (auto-detects if not provided)
- The workflow will:
- Install dependencies
- Run tests
- Remove the
-presuffix from version numbers - Create GitHub release and git tags with GPG signing
- Publish to npm
Version numbers follow the ExifTool version with an additional patch number when needed for package-specific changes.