diff --git a/docs/cli/usage.mdx b/docs/cli/usage.mdx index 0e8c5fce9..f6e06c966 100644 --- a/docs/cli/usage.mdx +++ b/docs/cli/usage.mdx @@ -34,10 +34,29 @@ infisical init ## Inject environment variables -```bash -# inject environment variables into app -infisical run -- [your application start command] -``` + + ```bash + # inject environment variables into app + infisical run -- [your application start command] + ``` + + + + Custom aliases can utilize secrets from Infisical. Suppose there is a custom alias `yd` in `custom.sh` that runs `yarn dev` and needs the secrets provided by Infisical. + ```bash + #!/bin/sh + + yd() { + yarn dev + } + ``` + + To make the secrets available from Infisical to `yd`, you can run the following command: + + ```bash + infisical run --command="source custom.sh && yd" + ``` + View all available options for `run` command [here](./commands/run)