Add persistent terminal aliases - #28
Draft
cursor[bot] wants to merge 1 commit into
Draft
Conversation
Co-authored-by: Jakob Langtry <jjalangtry@users.noreply.github.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.
Issue
Problem
The terminal UI advertises an
aliascommand, but the current implementation only prints a hard-coded example. That leaves a gap in the site's terminal-emulation goal: visitors cannot create shortcuts, inspect aliases, or remove them like they would in a real shell.Proposed improvement
Add persistent, shell-style alias management to the browser terminal. Aliases should be stored client-side, expand before command execution, preserve additional arguments, work with supported pipelines, and include loop protection.
Acceptance criteria
aliaslists saved aliases and explains how to create one when none exist.alias name='command'creates or replaces an alias.alias nameprints one alias or a not-found error.unalias nameremoves an alias;unalias -aclears all aliases.whichreports alias definitions.localStorage.Changes
src/lib/terminal/index.js.src/scripts/terminal.js, including pipeline aliases andwhich/tab-completion support.unaliasto the command surface and help/man documentation.README.md.Validation
pnpm test -- tests/unit/terminal.test.jspassed: 71 tests.pnpm checkpassed: lint, format check, coverage, and Astro build.<video src="/opt/cursor/artifacts/persistent_terminal_aliases_walkthrough.mp4" controls></video>