wee is a lightweight Bash-based tool to create and manage project-specific environments.
It integrates with mise to automatically load your environment when you enter a project directory and unload it when you leave.
This ensures your environment variables, aliases, and functions remain scoped to a single project without affecting your global shell setup.
- Define and manage environment variables local to your project
- Create and remove aliases for project-specific commands
- Add, overwrite, or remove functions scoped to the project
- Automatically manage setup and cleanup via
misehooks - Display all current project-specific configurations with a single command
Use basherbee to install: basherbee install chetanc10/wee
mise is automatically setup when installed with basherbee
wee <command> [args...]
wee create
This creates wee/mise configuration to setup and manage project environment. This is the first command to kickstart wee operations in a new project directory.
wee destroy
This destroys wee/mise setup from current project.
wee show
Displays following for current project setup with wee:
- Environment variables
- Startup and Cleanup commands run on project entry and exit respectively
- Bashit aliases/plugins
- Normal bash aliases
- Bash Functions
wee env <add|del> <var> [value]
- With
add→ Add a variable with given [value] - With
del→ Remove a variable.
Examples:
# Create DEBUG variable with value true
$ wee env add DEBUG true
# Create PORT variable with value 8080
$ wee env add PORT 8080
# Remove PORT variable
$ wee env del PORT # removes PORT
wee <start|clean> <add|del> [cmd]
start add [cmd]→ Update startup script with given commandclean add [cmd]→ Update cleanup script with given commandstart del→ Remove a command from startup scriptclean del→ Remove a command from cleanup script
Examples:
$ wee start add echo "git ls-files --others --exclude-standard"
$ wee start add echo "Grand changes happening in $PWD!"
$ wee start del
1) echo "git ls-files --others --exclude-standard" #cmd1
2) echo "Grand changes happening in ~/proj/curr-dir!" #cmd2
Select a command by index to delete: 2
wee alias <add|del> <name> [cmd]
- With
add→ Add an alias with given and [cmd]. - With
del→ Remove an alias.
Examples:
$ wee alias add ll "ls -lha"
$ wee alias del ll
wee func <add|del> <name>
- With
add→ Add a new function (you’ll be prompted to enter the body; pressCtrl+Dto finish). - With
del→ Remove a function.
Examples:
$ wee func add gcfg
Enter function body:
git config -l
$ wee func del gcfg # removes function 'gcfg'
When run inside a project directory, wee manages:
-
.mise.tomlProject-specific configuration used bymise. Created from wee-template.toml if missing. -
.mise-setup.shSourced on entering project directory. Contains aliases and functions. -
.mise-cleanup.shSourced on leaving project directory. Removes aliases and functions.
Sometimes, after updating wee environment, wee shows this:
Run 'rewee' to reload environment immediately
Running rewee helps reload environment with any change immediately