Skip to content

Add support for other shells#57

Open
Yusyuriv wants to merge 5 commits intomattrighetti:masterfrom
Yusyuriv:pr/add-other-shells
Open

Add support for other shells#57
Yusyuriv wants to merge 5 commits intomattrighetti:masterfrom
Yusyuriv:pr/add-other-shells

Conversation

@Yusyuriv
Copy link

@Yusyuriv Yusyuriv commented Feb 19, 2026

Why

I really liked the idea of the tool, but unfortunately I'm using Windows. The tool installed just fine, but it had no support for PowerShell.

Changes

By default, it keeps working just like before, this will keep working:

export $(envelope list dev)

I added a new argument, --shell, that changes the format of the output. It's optional, and by default it's set to kv (key-value pairs, just like before). In addition to that, it accepts some other values:

  • sh/bash/zsh:
    export API_KEY='sk_...'
    export ENV='dev'
    I did this because the original list of key-value pairs can fail if the values have spaces or some special characters in them.
  • nu/nushell:
    {"API_KEY": "sk_...", "ENV": "dev"}
  • cmd:
    set "API_KEY=sk_..."
    set "ENV=dev"
  • powershell/pwsh:
    $env:API_KEY = "sk_..."
    $env:ENV = "dev"

Docs

I updated man/envelope.1.md and README.md, feel free to let me know if I missed something or if you'd like to have something rephrased.

Tests

I added tests that verify outputs for each shell, including testing for correctly escaped special characters in each shell.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant