From: Michael Smith <michael.smith@cloudera.com>
To: zsh-workers@zsh.org
Subject: Bug: 'export FOO' not idempotent
Date: Mon, 27 Jun 2022 14:11:34 -0700 [thread overview]
Message-ID: <CAJV0PfLODd17k524MTGDkdsL0nYzsLL7tp08wXFxSU_uuuq+GA@mail.gmail.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 610 bytes --]
Environments tested:
- macOS 12.4, M1 chip, zsh 5.8.1 (x86_64-apple-darwin21.0)
- Ubuntu 20.04.4, zsh 5.8 (x86_64-ubuntu-linux-gnu)
If I repeat 'export FOO' to mark an environment variable not give it a
value, in bash it consistently does not show up in 'env':
$ export FOO
$ env | grep FOO
$ export FOO
$ env | grep FOO
but in zsh the 2nd invocation will set it to an empty string:
$ export FOO
$ env | grep FOO
$ export FOO
$ env | grep FOO
FOO=
This is an issue only because a project I'm building uses an empty export
for documentation, and it makes that project annoying to work with.
[-- Attachment #2: Type: text/html, Size: 3513 bytes --]
next reply other threads:[~2022-06-27 21:12 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-27 21:11 Michael Smith [this message]
2022-06-27 21:43 ` Lawrence Velázquez
2022-06-27 21:46 ` Michael Smith
2022-06-27 21:52 ` Lawrence Velázquez
2022-06-27 21:58 ` Roman Perepelitsa
2022-06-27 22:37 ` Lawrence Velázquez
2022-07-02 22:05 ` Bart Schaefer
2022-07-02 22:14 ` Bart Schaefer
2022-06-27 21:50 ` Roman Perepelitsa
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAJV0PfLODd17k524MTGDkdsL0nYzsLL7tp08wXFxSU_uuuq+GA@mail.gmail.com \
--to=michael.smith@cloudera.com \
--cc=zsh-workers@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).