* [bug#48501] [PATCH] daemon: Replace Unicode single quotes with poor simulacra.
@ 2021-05-18 16:34 Tobias Geerinckx-Rice via Guix-patches via
2021-05-18 17:13 ` Maxime Devos
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Tobias Geerinckx-Rice via Guix-patches via @ 2021-05-18 16:34 UTC (permalink / raw)
To: 48501
The correct ‘ and ’ are not considered word boundaries by some(?)
terminal emulators like Alacritty, making double-click selection
tedious. Avoid them in untranslated strings like it's 1992.
* nix/libstore/build.cc (UserLock::acquire)
(DerivationGoal::haveDerivation, DerivationGoal::closureRepaired)
(DerivationGoal::startBuilder, DerivationGoal::runChild)
(DerivationGoal::registerOutputs): Replace ‘’ with `' in output.
* nix/libstore/local-store.cc (canonicalisePathMetaData_)
(LocalStore::queryValidPathId): Likewise.
* nix/libstore/optimise-store.cc (LocalStore::optimisePath_): Likewise.
* nix/libutil/util.cc (readLink): Likewise.
---
nix/libstore/build.cc | 24 ++++++++++++------------
nix/libstore/local-store.cc | 4 ++--
nix/libstore/optimise-store.cc | 4 ++--
nix/libutil/util.cc | 2 +-
4 files changed, 17 insertions(+), 17 deletions(-)
diff --git a/nix/libstore/build.cc b/nix/libstore/build.cc
index 5697ae5a43..d6f9a15a46 100644
--- a/nix/libstore/build.cc
+++ b/nix/libstore/build.cc
@@ -525,7 +525,7 @@ void UserLock::acquire()
int err = getgrouplist(pw->pw_name, pw->pw_gid,
supplementaryGIDs.data(), &ngroups);
if (err == -1)
- throw Error(format("failed to get list of supplementary groups for ‘%1%’") % pw->pw_name);
+ throw Error(format("failed to get list of supplementary groups for `%1%’") % pw->pw_name);
supplementaryGIDs.resize(ngroups);
@@ -903,7 +903,7 @@ void DerivationGoal::haveDerivation()
trace("loading derivation");
if (nrFailed != 0) {
- printMsg(lvlError, format("cannot build missing derivation ‘%1%’") % drvPath);
+ printMsg(lvlError, format("cannot build missing derivation `%1%’") % drvPath);
done(BuildResult::MiscFailure);
return;
}
@@ -1058,7 +1058,7 @@ void DerivationGoal::closureRepaired()
{
trace("closure repaired");
if (nrFailed > 0)
- throw Error(format("some paths in the output closure of derivation ‘%1%’ could not be repaired") % drvPath);
+ throw Error(format("some paths in the output closure of derivation `%1%’ could not be repaired") % drvPath);
done(BuildResult::AlreadyValid);
}
@@ -1748,10 +1748,10 @@ void DerivationGoal::startBuilder()
printMsg(lvlChatty, format("setting up chroot environment in `%1%'") % chrootRootDir);
if (mkdir(chrootRootDir.c_str(), 0750) == -1)
- throw SysError(format("cannot create ‘%1%’") % chrootRootDir);
+ throw SysError(format("cannot create `%1%’") % chrootRootDir);
if (chown(chrootRootDir.c_str(), 0, buildUser.getGID()) == -1)
- throw SysError(format("cannot change ownership of ‘%1%’") % chrootRootDir);
+ throw SysError(format("cannot change ownership of `%1%’") % chrootRootDir);
/* Create a writable /tmp in the chroot. Many builders need
this. (Of course they should really respect $TMPDIR
@@ -1808,7 +1808,7 @@ void DerivationGoal::startBuilder()
chmod_(chrootStoreDir, 01775);
if (chown(chrootStoreDir.c_str(), 0, buildUser.getGID()) == -1)
- throw SysError(format("cannot change ownership of ‘%1%’") % chrootStoreDir);
+ throw SysError(format("cannot change ownership of `%1%’") % chrootStoreDir);
foreach (PathSet::iterator, i, inputPaths) {
struct stat st;
@@ -2007,13 +2007,13 @@ void DerivationGoal::runChild()
local to the namespace, though, so setting MS_PRIVATE
does not affect the outside world. */
if (mount(0, "/", 0, MS_REC|MS_PRIVATE, 0) == -1) {
- throw SysError("unable to make ‘/’ private mount");
+ throw SysError("unable to make `/’ private mount");
}
/* Bind-mount chroot directory to itself, to treat it as a
different filesystem from /, as needed for pivot_root. */
if (mount(chrootRootDir.c_str(), chrootRootDir.c_str(), 0, MS_BIND, 0) == -1)
- throw SysError(format("unable to bind mount ‘%1%’") % chrootRootDir);
+ throw SysError(format("unable to bind mount `%1%’") % chrootRootDir);
/* Set up a nearly empty /dev, unless the user asked to
bind-mount the host /dev. */
@@ -2423,7 +2423,7 @@ void DerivationGoal::registerOutputs()
if (pathExists(dst)) deletePath(dst);
if (rename(actualPath.c_str(), dst.c_str()))
throw SysError(format("renaming `%1%' to `%2%'") % actualPath % dst);
- throw Error(format("derivation `%1%' may not be deterministic: output `%2%' differs from ‘%3%’")
+ throw Error(format("derivation `%1%' may not be deterministic: output `%2%' differs from `%3%’")
% drvPath % path % dst);
} else
throw Error(format("derivation `%1%' may not be deterministic: output `%2%' differs")
@@ -2501,11 +2501,11 @@ void DerivationGoal::registerOutputs()
Path prev = i->path + checkSuffix;
if (pathExists(prev))
throw NotDeterministic(
- format("output ‘%1%’ of ‘%2%’ differs from ‘%3%’ from previous round")
+ format("output `%1%’ of `%2%’ differs from `%3%’ from previous round")
% i->path % drvPath % prev);
else
throw NotDeterministic(
- format("output ‘%1%’ of ‘%2%’ differs from previous round")
+ format("output `%1%’ of `%2%’ differs from previous round")
% i->path % drvPath);
}
assert(false); // shouldn't happen
@@ -2518,7 +2518,7 @@ void DerivationGoal::registerOutputs()
if (curRound < nrRounds) {
Path dst = i.second.path + checkSuffix;
if (rename(i.second.path.c_str(), dst.c_str()))
- throw SysError(format("renaming ‘%1%’ to ‘%2%’") % i.second.path % dst);
+ throw SysError(format("renaming `%1%’ to `%2%’") % i.second.path % dst);
}
}
diff --git a/nix/libstore/local-store.cc b/nix/libstore/local-store.cc
index 675d1ba66f..8b9c9bebd5 100644
--- a/nix/libstore/local-store.cc
+++ b/nix/libstore/local-store.cc
@@ -380,7 +380,7 @@ static void canonicalisePathMetaData_(const Path & path, uid_t fromUid, InodesSe
/* Really make sure that the path is of a supported type. */
if (!(S_ISREG(st.st_mode) || S_ISDIR(st.st_mode) || S_ISLNK(st.st_mode)))
- throw Error(format("file ‘%1%’ has an unsupported type") % path);
+ throw Error(format("file `%1%’ has an unsupported type") % path);
/* Fail if the file is not owned by the build user. This prevents
us from messing up the ownership/permissions of files
@@ -647,7 +647,7 @@ uint64_t LocalStore::queryValidPathId(const Path & path)
{
auto use(stmtQueryPathInfo.use()(path));
if (!use.next())
- throw Error(format("path ‘%1%’ is not valid") % path);
+ throw Error(format("path `%1%’ is not valid") % path);
return use.getInt(0);
}
diff --git a/nix/libstore/optimise-store.cc b/nix/libstore/optimise-store.cc
index eb303ab4c3..2662253b91 100644
--- a/nix/libstore/optimise-store.cc
+++ b/nix/libstore/optimise-store.cc
@@ -181,12 +181,12 @@ void LocalStore::optimisePath_(OptimiseStats & stats, const Path & path, InodeHa
}
if (st.st_size != stLink.st_size) {
- printMsg(lvlError, format("removing corrupted link ‘%1%’") % linkPath);
+ printMsg(lvlError, format("removing corrupted link `%1%’") % linkPath);
unlink(linkPath.c_str());
goto retry;
}
- printMsg(lvlTalkative, format("linking ‘%1%’ to ‘%2%’") % path % linkPath);
+ printMsg(lvlTalkative, format("linking `%1%’ to `%2%’") % path % linkPath);
/* Make the containing directory writable, but only if it's not
the store itself (we don't want or need to mess with its
diff --git a/nix/libutil/util.cc b/nix/libutil/util.cc
index 69f1c634a9..cf5099a4fe 100644
--- a/nix/libutil/util.cc
+++ b/nix/libutil/util.cc
@@ -202,7 +202,7 @@ Path readLink(const Path & path)
if (rlsize == -1)
throw SysError(format("reading symbolic link '%1%'") % path);
else if (rlsize > st.st_size)
- throw Error(format("symbolic link ‘%1%’ size overflow %2% > %3%")
+ throw Error(format("symbolic link `%1%’ size overflow %2% > %3%")
% path % rlsize % st.st_size);
return string(buf, st.st_size);
}
--
2.31.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [bug#48501] [PATCH] daemon: Replace Unicode single quotes with poor simulacra.
2021-05-18 16:34 [bug#48501] [PATCH] daemon: Replace Unicode single quotes with poor simulacra Tobias Geerinckx-Rice via Guix-patches via
@ 2021-05-18 17:13 ` Maxime Devos
2021-05-21 10:28 ` Ludovic Courtès
2021-05-21 14:23 ` Thiago Jung Bauermann via Guix-patches via
2 siblings, 0 replies; 4+ messages in thread
From: Maxime Devos @ 2021-05-18 17:13 UTC (permalink / raw)
To: Tobias Geerinckx-Rice, 48501
[-- Attachment #1: Type: text/plain, Size: 1166 bytes --]
Tobias Geerinckx-Rice via Guix-patches via schreef op di 18-05-2021 om 18:34 [+0200]:
> The correct ‘ and ’ are not considered word boundaries by some(?)
> terminal emulators like Alacritty, making double-click selection
> tedious. Avoid them in untranslated strings like it's 1992.
N months later, while Tobias Geerinckx-Rice is asleep, a new patch appears:
Typographically Correct via Guix-patches [...]
> It isn't 1992 anymore; the proper ‘ and ’ quotation marks are now
> well-supported in software. Use the typographically-correct ‘ and ’
> in the English translation instead of the unrelated characters ` and '.
>
> [...]
FWIW, double-click seems to work well in Emacs, Gnome Terminal.
Instead of working-around bugs, can ‘we’ fix the bug in Alacritty?
Or at least, open a bug report?
Unfortunately, GitHub's TOS and Privacy Policy were ... not great
last time I checked, though I can't find the ‘badness’ anymore except
for some weird section on ‘idemnity’. In any case, there is an #alacritty
channel:
<https://github.com/alacritty/alacritty/blob/master/CONTRIBUTING.md#contact>
Greetings,
Maxime.
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 260 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* [bug#48501] [PATCH] daemon: Replace Unicode single quotes with poor simulacra.
2021-05-18 16:34 [bug#48501] [PATCH] daemon: Replace Unicode single quotes with poor simulacra Tobias Geerinckx-Rice via Guix-patches via
2021-05-18 17:13 ` Maxime Devos
@ 2021-05-21 10:28 ` Ludovic Courtès
2021-05-21 14:23 ` Thiago Jung Bauermann via Guix-patches via
2 siblings, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2021-05-21 10:28 UTC (permalink / raw)
To: Tobias Geerinckx-Rice; +Cc: 48501
Hi,
Tobias Geerinckx-Rice <me@tobias.gr> skribis:
> The correct ‘ and ’ are not considered word boundaries by some(?)
> terminal emulators like Alacritty, making double-click selection
> tedious. Avoid them in untranslated strings like it's 1992.
>
> * nix/libstore/build.cc (UserLock::acquire)
> (DerivationGoal::haveDerivation, DerivationGoal::closureRepaired)
> (DerivationGoal::startBuilder, DerivationGoal::runChild)
> (DerivationGoal::registerOutputs): Replace ‘’ with `' in output.
> * nix/libstore/local-store.cc (canonicalisePathMetaData_)
> (LocalStore::queryValidPathId): Likewise.
> * nix/libstore/optimise-store.cc (LocalStore::optimisePath_): Likewise.
> * nix/libutil/util.cc (readLink): Likewise.
> ---
> nix/libstore/build.cc | 24 ++++++++++++------------
> nix/libstore/local-store.cc | 4 ++--
> nix/libstore/optimise-store.cc | 4 ++--
> nix/libutil/util.cc | 2 +-
> 4 files changed, 17 insertions(+), 17 deletions(-)
No objection from me!
Ludo’.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [bug#48501] [PATCH] daemon: Replace Unicode single quotes with poor simulacra.
2021-05-18 16:34 [bug#48501] [PATCH] daemon: Replace Unicode single quotes with poor simulacra Tobias Geerinckx-Rice via Guix-patches via
2021-05-18 17:13 ` Maxime Devos
2021-05-21 10:28 ` Ludovic Courtès
@ 2021-05-21 14:23 ` Thiago Jung Bauermann via Guix-patches via
2 siblings, 0 replies; 4+ messages in thread
From: Thiago Jung Bauermann via Guix-patches via @ 2021-05-21 14:23 UTC (permalink / raw)
To: 48501; +Cc: Tobias Geerinckx-Rice
Hello,
[ I'm just an onlooker on the Guix mailing lists, so don't assign much
weight to this comment. ]
Em terça-feira, 18 de maio de 2021, às 13:34:05 -03, Tobias Geerinckx-Rice
via Guix-patches via escreveu:
> The correct ‘ and ’ are not considered word boundaries by some(?)
> terminal emulators like Alacritty, making double-click selection
> tedious. Avoid them in untranslated strings like it's 1992.
>
> * nix/libstore/build.cc (UserLock::acquire)
> (DerivationGoal::haveDerivation, DerivationGoal::closureRepaired)
> (DerivationGoal::startBuilder, DerivationGoal::runChild)
> (DerivationGoal::registerOutputs): Replace ‘’ with `' in output.
> * nix/libstore/local-store.cc (canonicalisePathMetaData_)
> (LocalStore::queryValidPathId): Likewise.
> * nix/libstore/optimise-store.cc (LocalStore::optimisePath_): Likewise.
> * nix/libutil/util.cc (readLink): Likewise.
> ---
> nix/libstore/build.cc | 24 ++++++++++++------------
> nix/libstore/local-store.cc | 4 ++--
> nix/libstore/optimise-store.cc | 4 ++--
> nix/libutil/util.cc | 2 +-
> 4 files changed, 17 insertions(+), 17 deletions(-)
>
> diff --git a/nix/libstore/build.cc b/nix/libstore/build.cc
> index 5697ae5a43..d6f9a15a46 100644
> --- a/nix/libstore/build.cc
> +++ b/nix/libstore/build.cc
> @@ -525,7 +525,7 @@ void UserLock::acquire()
> int err = getgrouplist(pw->pw_name, pw->pw_gid,
> supplementaryGIDs.data(), &ngroups);
> if (err == -1)
> - throw Error(format("failed to get list of supplementary
> groups for ‘%1%’") % pw->pw_name); + throw
> Error(format("failed to get list of supplementary groups for `%1%’") %
> pw->pw_name);
IMHO the backtick looks ugly when it tries to mimick the opening quote
character. I think the text looks better if both quote characters are
replaced with the straight quote character, e.g. '%1'.
--
Regards from the peanut gallery,
Thiago
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2021-05-21 14:24 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-05-18 16:34 [bug#48501] [PATCH] daemon: Replace Unicode single quotes with poor simulacra Tobias Geerinckx-Rice via Guix-patches via
2021-05-18 17:13 ` Maxime Devos
2021-05-21 10:28 ` Ludovic Courtès
2021-05-21 14:23 ` Thiago Jung Bauermann via Guix-patches via
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
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 read-only IMAP folder(s) and NNTP newsgroup(s).