Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion apps/imagekit/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@ponti-studios/imagekit",
"version": "1.1.0",
"version": "1.1.1",
"description": "Image asset toolkit — resize, optimize, crop, convert, strip metadata, analyze EXIF, and generate web icons from the command line",
"keywords": [
"avif",
Expand Down
3 changes: 2 additions & 1 deletion apps/imagekit/src/commands/integration.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import {
runSource,
tempDir,
} from "../test-support";
import pkg from "../../package.json";

const temporaryDirs: string[] = [];

Expand Down Expand Up @@ -215,7 +216,7 @@ describe("iconkit binary fixture matrix", () => {
expect(result.exitCode).toBe(0);
expect(fs.readFileSync(destination, "utf8")).toContain(APP_DIR);
expect(version.exitCode).toBe(0);
expect(version.stdout.toString().trim()).toBe("1.0.0");
expect(version.stdout.toString().trim()).toBe(pkg.version);
});

test("handles a broken existing symlink without crashing", () => {
Expand Down
3 changes: 2 additions & 1 deletion apps/imagekit/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import { cmdFixDates } from "./commands/fix-dates";
import { cmdRename } from "./commands/rename";
import { cmdGenerate } from "./commands/generate";
import { DATE_PATTERN_HELP } from "./date-patterns";
import pkg from "../package.json";

// Detect invocation name for help text: imagekit is primary, but support iconkit/photokit aliases
const invokedAs = path.basename(process.execPath).toLowerCase().includes("iconkit")
Expand All @@ -29,7 +30,7 @@ program
.description(
"Image asset toolkit — resize, optimize, analyze EXIF, fix dates, rename, and generate web icons from the command line",
)
.version("1.0.0");
.version(pkg.version);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Update the manifest-driven version assertion

When the imagekit integration phase runs, scripts/test-clis.sh builds the binary and invokes scripts/cli/integration/imagekit.sh, whose line 30 still requires --version to contain 1.0.0. This line now makes the binary emit 1.1.1, so that grep exits nonzero and the macOS CI integration job fails; update the shell assertion to expect or derive the current package version.

Useful? React with 👍 / 👎.


// Keep primary name as imagekit for help, but allow alias detection for version output
// Ensure --version works regardless of invoked name
Expand Down
1 change: 1 addition & 0 deletions apps/imagekit/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
"moduleResolution": "bundler",
"strict": true,
"esModuleInterop": true,
"resolveJsonModule": true,
"skipLibCheck": true,
"types": ["node", "bun"],
"outDir": "dist",
Expand Down
5 changes: 3 additions & 2 deletions scripts/cli/integration/imagekit.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,6 @@ cp "$fixtures/metadata-exif.jpg" "$tmpdir/photo.jpg"
"$binary" strip "$tmpdir/photo.jpg"
"$binary" info "$tmpdir/photo.jpg" | grep -qi "photo.jpg"

# version surfaces with the imagekit identity
"$binary" --version | grep -q "1.0.0"
# version surfaces and matches package.json
expected_version="$(node -p "require('$repo_root/apps/imagekit/package.json').version")"
"$binary" --version | grep -q "$expected_version"