ENV(1)
π ENV(1) β ok bestie, we're doing environment surgery today β¨
Hiii so this is the page for env(1), one of the Perl-contributed manual pages, and honestly? It's a little icon and it deserves your attention. Sit down, grab a strawberry π, we're gonna run a program in a modified environment. No cap.
π SYNOPSIS π
env [-i] [-u name]... [name=value]... [command [args]...]
That's the whole vibe. Flags, then some name=value pairs, then optionally the command you actually wanna run (plus its args). Easy. π
β¨ DESCRIPTION β¨
So env runs a command with the environment modified exactly however you specified it on the command line. That's it, that's the job. π«Ά
But here's the cute part: if you don't specify a command? Then env just prints out the modified environment for you to look at. It's giving "show me what you did" main character energy. π
πΈ OPTIONS πΈ
env accepts the following options, and yes they're both little legends:
-iβ Clears the environment entirely, passing only the values you specified along to the command. Full reset, clean slate, new semester energy. β¨-unameβ Clears the environment variablenameif it exists. The value must not include the=character. Oh and you can repeat this option as many times as you want β stack 'em, bestie. π
π©Ί DIAGNOSTICS π©Ί
Okay so if the command actually gets invoked, the exit status of env is the exit status of that command. Simple inheritance, we love to see it. π§¬
Otherwise β like, if you didn't run a command β env will return one of these:
0 env completed successfully.
1-125 An error occurred in env.
127 There was an error running the command specified.
Memorize 127 fr fr, it's the "couldn't run the thing" one and it WILL show up in your life. π
π BUGS π
env has no known bugs. Yeah. That's what it says. Genuinely flawless, lowkey. Not me being jealous of a program π
π AUTHOR π
This Perl version of env was written by Matthew Bafford, dragons@scescape.net. Legend behavior. π
π COPYRIGHT and LICENSE π
This program is copyright (c) Matthew Bafford 1999. Yes, 1999 β an elder, and it still ate. π
This program is free and open software. You may use, modify, distribute, and sell this program (and any modified variants) in any way you wish, provided you do not restrict others from doing the same. Like, share the love, don't gatekeep. π«Ά That's the whole rule.
Ok that's everything, every flag, every exit code, every word from the original β nothing dropped, nothing invented. Vibe check passed. π¦
perl v5.42.2 π§ and dated 2026-02-15 β so like, this page is from the future, slay. Byeee, go modify an environment responsibly bestie! πβ¨πΈ
π¦ where this page comes from
- alpine 3.24: perl-power-tools-doc 1.053-r1 Β· GPL-2.0-or-later AND Artistic-1.0-Perl AND Artistic-2.0 AND BSD-2-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms