Repository navigation
Settings › License: paste a key, see the plan, refresh it - #381
Merged
Merged
Conversation
The third step of docs/design/license.md: a page of its own, before About, as packwing's. - Without a key: the plans and their prices (Pro and Business coming soon), Buy Plus, which opens the portal's /pricing/shellwing (it sells Plus and starts the 14-day trial), and a field to paste a key, with Activate (or Enter). - With one: the plan it gives now, who it is issued to and until when (past its end, the grace left, then Free since), Refresh, Manage subscription (the portal's subscriptions) and Remove. - The key is this device's own: kept in the vault as a device secret (license-key), sealed with its key, never synced. It is read when the vault opens, at start or when unlocked. - [license] refresh (on by default, this device's own): the portal is asked once a day, with the key alone, and a newer key of the same license is kept; nothing else is. Off, the key lasts to its end. - Workspace::plan says what the key gives now: Free without one. Nothing is limited by it yet: the limits are the next step. core: the portal's pricing and subscriptions pages, from the portal shellwing talks to, in place of shellwing.app/pricing, which is not made. UI tests (no scenario reaches the portal: SHELLWING_PORTAL is a closed port in the child, a refresh asks a server of the test's): a key taken, kept and removed, another product's refused; an ended trial is Free; Refresh takes a newer key of the same license and not another license's. The keys are the portal signer's, to 2099, so they pass on any day. 35 strings in 14 languages. Co-Authored-By: Claude Opus 5.5 <[email protected]>
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.
Step 3 of
docs/design/license.md: a License page of its own in Settings, just before About, as in packwing. Nothing is limited yet:Workspace::plan()reports the plan, and step 4 applies the limits.The page
Without a key:
/pricing/shellwing(portal Host rail: status dot over the active tile's ring #33), which sells Plus and starts the 14-day trial.With a key:
[license] refresh.The page shows "Until …" and not "Renews …", because a key does not say whether its subscription renews.
The key
license-key). It never syncs.[license] refreshis on by default and belongs to this device; it is not among the synced settings. While it is on, the portal is asked once a day for a newer key, with the key alone. Only a newer key of the same license is kept.core: Buy and Manage subscription open the portal's pages, whichpricing_page()andsubscriptions_page()build from the portal shellwing talks to. Before, they pointed at shellwing.app/pricing, which does not exist yet.Tests
UI tests, in
ui_tests/license.rs. No scenario reaches the portal:SHELLWING_PORTALis a closed port in the child process, and a refresh asks a server the test runs.The keys come from the portal's own signer and are valid until 2099, so the tests pass on any day. How to make them again is in
crates/core/testdata/license/README.md.Run:
make lint,cargo clippy -p shellwing --features ui-tests --all-targets -D warnings,i18n.py check, the license UI tests, and the tests for core license and config. The rest of the UI tests were not run here; CI runs them.Not checked: how the page looks on screen. The UI tests check what it shows, not the layout.
Docs: the License section in
docs/configuration.md, and[license]in the sampleconfig.toml. 36 strings in 14 languages.🤖 Generated with Claude Code