[PR #182] [MERGED] [cli] Take the creator name as a positional argument #181

Closed
opened 2026-10-13 19:48:27 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Glitchy-Sheep/boosty-downloader/pull/182
Author: @Glitchy-Sheep
Created: 9/13/2026
Status: ✅ Merged
Merged: 9/13/2026
Merged by: @Glitchy-Sheep

Base: main ← Head: feat/positional-username


📝 Commits (1)

  • 1c17152 feat!: Take the creator name as a positional argument

📊 Changes

7 files changed (+31 additions, -18 deletions)

View changed files

📝 CHANGELOG.md (+4 -0)
📝 README.md (+1 -1)
📝 boosty_downloader/cli/cli_options.py (+5 -5)
📝 boosty_downloader/cli/commands/check.py (+2 -2)
📝 boosty_downloader/cli/commands/clean_cache.py (+2 -2)
📝 boosty_downloader/cli/commands/download.py (+4 -4)
📝 test/unit/cli/cli_smoke_test.py (+13 -4)

📄 Description

📝 Summary

download, check and clean-cache cannot do anything without a creator name, so the name is now their first argument instead of a flag:

boosty-downloader download <username>
boosty-downloader check <username>
boosty-downloader clean-cache <username>

🔧 What changes

  • UsernameArgument in cli_options.py replaces UsernameOption; the three commands read it as a positional parameter
  • Command help, the README usage line and the changelog show the new form (Changed, marked BREAKING)

⚠️ Breaking change

The -u / --username flag is gone, on purpose and without an alias. Typer answers No such option: -u for the old form and Missing argument 'USERNAME' when the name is missing, both with exit code 2, so scripts fail loudly rather than silently doing something else.

show-auth-script takes no name and is untouched.

🧪 Tests

  • CLI smoke: each of the three commands without a name is a usage error (exit 2, names USERNAME); the old -u flag is rejected
  • Live: check <username>, download <username> --dry-run -f files, check -u <username> (rejected), check (missing argument), download --help

✅ Checklist

  • Tested live on a real blog (feature or fix)
  • Updated CLI --help and README if needed
  • Updated docs/ if the download flow or dev process changed
  • Added a line to ## Unreleased in CHANGELOG.md (or the ci/skip-changelog label if not user-facing)

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Glitchy-Sheep/boosty-downloader/pull/182 **Author:** [@Glitchy-Sheep](https://github.com/Glitchy-Sheep) **Created:** 9/13/2026 **Status:** ✅ Merged **Merged:** 9/13/2026 **Merged by:** [@Glitchy-Sheep](https://github.com/Glitchy-Sheep) **Base:** `main` ← **Head:** `feat/positional-username` --- ### 📝 Commits (1) - [`1c17152`](https://github.com/Glitchy-Sheep/boosty-downloader/commit/1c17152b74e703119c3810362edce84cc00ad1cb) feat!: Take the creator name as a positional argument ### 📊 Changes **7 files changed** (+31 additions, -18 deletions) <details> <summary>View changed files</summary> 📝 `CHANGELOG.md` (+4 -0) 📝 `README.md` (+1 -1) 📝 `boosty_downloader/cli/cli_options.py` (+5 -5) 📝 `boosty_downloader/cli/commands/check.py` (+2 -2) 📝 `boosty_downloader/cli/commands/clean_cache.py` (+2 -2) 📝 `boosty_downloader/cli/commands/download.py` (+4 -4) 📝 `test/unit/cli/cli_smoke_test.py` (+13 -4) </details> ### 📄 Description ## 📝 Summary `download`, `check` and `clean-cache` cannot do anything without a creator name, so the name is now their first argument instead of a flag: ``` boosty-downloader download <username> boosty-downloader check <username> boosty-downloader clean-cache <username> ``` ## 🔧 What changes - `UsernameArgument` in `cli_options.py` replaces `UsernameOption`; the three commands read it as a positional parameter - Command help, the README usage line and the changelog show the new form (`Changed`, marked BREAKING) ## ⚠️ Breaking change The `-u` / `--username` flag is gone, on purpose and without an alias. Typer answers `No such option: -u` for the old form and `Missing argument 'USERNAME'` when the name is missing, both with exit code 2, so scripts fail loudly rather than silently doing something else. `show-auth-script` takes no name and is untouched. ## 🧪 Tests - CLI smoke: each of the three commands without a name is a usage error (exit 2, names `USERNAME`); the old `-u` flag is rejected - Live: `check <username>`, `download <username> --dry-run -f files`, `check -u <username>` (rejected), `check` (missing argument), `download --help` ## ✅ Checklist - [x] Tested live on a real blog (feature or fix) - [x] Updated CLI `--help` and README if needed - [x] Updated `docs/` if the download flow or dev process changed - [x] Added a line to `## Unreleased` in CHANGELOG.md (or the `ci/skip-changelog` label if not user-facing) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-13 19:48:27 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Glitchy-Sheep/boosty-downloader#181
No description provided.