Skip to content

feat: add scale option to get command YAML config#4

Merged
erickzanardo merged 4 commits intomainfrom
copilot/add-scaling-to-get-command
Apr 3, 2026
Merged

feat: add scale option to get command YAML config#4
erickzanardo merged 4 commits intomainfrom
copilot/add-scaling-to-get-command

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Apr 3, 2026

The get command lacked the scaling capability already available in export --scale-size. This adds a per-file scale field to the pepper-sprite.yaml config.

Changes

  • FileConfig — new optional scale: String? field
  • _parseConfig() — reads scale from each YAML file entry
  • _processFile() — validates scale format (WIDTH,HEIGHT, positive integers, whitespace-tolerant) before download; logs error and marks file as failed on invalid input
  • _exportFile() — accepts scaleWidth/scaleHeight and forwards them to ImageExporter.exportToPngFile()
  • Tests — 4 new validation cases (non-numeric, single value, zero width, negative height)

Usage

files:
  - fileId: "ADasdQWEsd"
    output: "assets/images/buildings.png"
    scale: "512,512"

Invalid scale values cause that file to fail (counted in the error summary) without aborting remaining files.

Copilot AI linked an issue Apr 3, 2026 that may be closed by this pull request
Copilot AI changed the title [WIP] Add scaling option to get command feat: add scale option to get command YAML config Apr 3, 2026
Copilot AI requested a review from erickzanardo April 3, 2026 15:59
@erickzanardo erickzanardo marked this pull request as ready for review April 3, 2026 16:00
@erickzanardo erickzanardo merged commit 1072237 into main Apr 3, 2026
4 checks passed
@erickzanardo erickzanardo deleted the copilot/add-scaling-to-get-command branch April 3, 2026 16:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: add scaling to the get command

2 participants