gon env
Manage .env files on remote servers. Pull, push, or update individual variables.
Commands
gon env:pull [environment] # Download .env from servergon env:push [environment] [--restart] # Upload .env to servergon env:set KEY=VALUE [environment] # Set single variable on server
Default environment is production. Host is resolved from ~/.gon/servers.json.
env:pull
Downloads the remote .env and saves it locally as .env.production.
gon env:pullgon env:pull staging
env:push
Uploads a local .env.{environment} file to the server. Shows confirmation before overwriting.
gon env:push # Upload .env.productiongon env:push --force # Skip confirmationgon env:push --restart # Restart app + clear config cache
env:set
Update or add a single variable on the remote server. Automatically restarts the app and clears config cache.
gon env:set APP_DEBUG=truegon env:set MAIL_HOST=smtp.example.com production