Add image download, config file support, and CLI improvements#187
Open
chenxiccc wants to merge 2 commits intokepano:mainfrom
Open
Add image download, config file support, and CLI improvements#187chenxiccc wants to merge 2 commits intokepano:mainfrom
chenxiccc wants to merge 2 commits intokepano:mainfrom
Conversation
- Add --download-images flag to download remote images in markdown and rewrite links to local paths - Add --image-dir and --image-dir-from-output options to control image save location (default: attachments/) - Auto-generate output filename from URL when --download-images is set without --output - Add defuddle.config.json / .defuddlerc config file support for default CLI options (loaded when no manual flags are passed) - Fix getPageName URL path extraction (use basename instead of broken regex) - Add defuddle.config.json with markdown + download-images + attachments defaults - Update README with new options and config file documentation Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…pixel filter - Add fetchImageWithRetry to replace bare fetch calls: - Send Referer and browser User-Agent headers to bypass hotlink protection - Retry up to 3 times with 1500ms delay on transient errors; skip retry on 4xx - Validate Content-Type to reject non-image responses (e.g. HTML error pages) - Skip files smaller than 1KB to filter out tracking pixels Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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.
Add --download-images flag to download remote images in markdown and rewrite links to local paths
Add --image-dir and --image-dir-from-output options to control image save location (default: attachments/)
Auto-generate output filename from URL when --download-images is set without --output
Add defuddle.config.json / .defuddlerc config file support for default CLI options (loaded when no manual flags are passed)
Update README with new options and config file documentation