[Changed Subscribers] D10912: rhg: add ui.plain() and check it before showing relative paths in status
SimonSapin
phabricator at mercurial-scm.org
Fri Jun 25 09:48:42 UTC 2021
SimonSapin added inline comments.
INLINE COMMENTS
> ui.rs:70-73
> + match env::var("HGPLAIN") {
> + Ok(_) => true,
> + Err(_) => false,
> + }
This can be spelled `env::var("HGPLAIN").is_ok()`.
However `env::var` has two error cases. If we only want to check for the presence of a variable regardless of its Unicode validity, `env::var_os("HGPLAIN").is_some()` should be used instead.
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST ACTION
https://phab.mercurial-scm.org/D10912/new/
REVISION DETAIL
https://phab.mercurial-scm.org/D10912
To: pulkit, #hg-reviewers
Cc: SimonSapin, mercurial-patches
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-patches/attachments/20210625/834fb8d9/attachment-0002.html>
More information about the Mercurial-patches
mailing list