This repository was archived by the owner on Aug 13, 2026. It is now read-only.
Add multi-environment mode and one-command setup feature - #20
Open
Tharun-DV wants to merge 2 commits into
Open
Conversation
Add two major features to try: 1. Multi-environment mode (--base) - `try init --base ~/src` organizes workspaces into multiple environments (tries, experiments, prod) under a base directory - Two-step TUI: first pick an environment, then pick/create a project - Each subdirectory of the base path becomes an environment - New environments can be created on-the-fly by typing a name - ENV mode disables delete/rename (only projects get those) - Fully backward compatible: single-root mode unchanged 2. One-command setup (--install) - `try init --base ~/src --install` does everything: - Creates the base directory and default env subdirs - Auto-detects shell (zsh/bash/fish) from $SHELL - Appends shell function to the right config file - Skips if a try function is already present - All output goes to stderr (nothing on stdout) to prevent accidental eval side effects Files changed: src/tui.h - SelectorMode enum (SELECTOR_FOLDERS, SELECTOR_ENVS) src/tui.c - ENV mode rendering (title, footer, no delete/rename) src/commands.h - Updated signatures with base_path parameter src/commands.c - --base/--install parsing, env subdir creation, rc file detection, duplicate check, two-step selector src/main.c - --base flag, multi-env path resolution, updated help README.md - New multi-env docs, --install walkthrough, comparison
feat: add multi-environment mode and --install flag
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 freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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 two major features to try:
Multi-environment mode (--base)
try init --base ~/srcorganizes workspaces into multipleenvironments (tries, experiments, prod) under a base directory
One-command setup (--install)
try init --base ~/src --installdoes everything:accidental eval side effects