Repository navigation
Conversation
The command-line file argument was only handled on Windows, so on Linux double-clicking an .ink file (or running 'inky story.ink') always opened an untitled story. Also use the matched argument instead of always argv[1], and resolve relative paths. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
|
Interesting, but you also need me to add the %f argument to resources/com.inkle.inky.desktop |
Co-Authored by: Claude
Author
Good catch, you're right. I've tested it on my own .desktop which already had the %f. |
Sal3k
force-pushed
the
fix-linux-open-file
branch
from
November 1, 2026 10:20
0a58fc2 to
7589e40
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes the Linux part of #80.
Problem
On Linux, opening an .ink file via double-click (file association /
.desktop%f) orinky /path/story.inkalways opens a new untitled story. The command-line argument was only handled whenprocess.platform == "win32".Changes (
app/main-process/main.js).inkargument on all platforms except macOS (which uses theopen-fileevent).process.argv[1](also affected Windows when the file was not the first argument).path.resolve.Tested on CachyOS (Arch-based), KDE Plasma 6:
npm start -- /absolute/path/story.inkand a relative path: file opens.%f: file opens.Found and fixed with help from Claude.
🤖 Generated with Claude Code