mirror of
https://github.com/netblue30/firejail.git
synced 2026-05-15 14:16:14 -06:00
[GH-ISSUE #5903] docs: non-ASCII hyphens in commands - copy pasting them fails on command line #3128
Labels
No labels
LTS merge
LTS merge
bug
bug
converted-to-discussion
doc-todo
documentation
duplicate
enhancement
file-transfer
firecfg
firejail-in-firejail
firetools
graphics
help wanted
information_old
installation
invalid
modif
moved
needinfo
networking
notabug
notourbug
old-version
overlayfs
packaging
profile-request
pull-request
question
question_old
removal
runtime-permissions
sandbox-ipc
security
stale
wiki
wiki
wontfix
wordpress
workaround
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/firejail#3128
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @danielkrajnik on GitHub (Jul 16, 2023).
Original GitHub issue: https://github.com/netblue30/firejail/issues/5903
Description
Copying flags from man pages doesn't work - hyphens are encoded as
e280 90instead2d.They will look the same, but firejail will error (for example):
Steps to Reproduce
man firejail/ --writable‐run‐userfirejail --writable‐run‐user*5. paste it into a hex editor:
Expected Behaviour
enter shell in firejail with
/run/user/$UID/gnupgavailableActual Behaviour
Error: invalid --writable‐run‐user command line optionEnvironment
Checklist
/usr/bin/vlc) "fixes" it).https://github.com/netblue30/firejail/issues/1139)browser-allow-drm yes/browser-disable-u2f noinfirejail.configto allow DRM/U2F in browsers.--profile=PROFILENAMEto set the right profile. (Only relevant for AppImages)@vinc17fr commented on GitHub (Sep 26, 2023):
This is due to the fact that some "-" characters are not escaped with a backslash.
@ghost commented on GitHub (Sep 26, 2023):
@danielkrajnik When doing the 4 steps to reproduce (in my preferred xfce4-terminal) it actually works fine for me:
Perhaps it's dependent on the terminal-emulator? Have you tried a different one than what you normally use yet?
@rusty-snake commented on GitHub (Sep 26, 2023):
@glitsj16 even if it does not happen with all terminals/viewer/... the format is wrong. See @vinc17fr post which writes it down the first time.
Has nothing todo with writable-run-user.
@danielkrajnik commented on GitHub (Sep 26, 2023):
Strange, it is working for me now as well even though it's the same terminal (alacritty). Maybe switching from Wayland to X11? Or maybe something else changed since July.
@ghost commented on GitHub (Sep 26, 2023):
@rusty-snake
The format might be wrong, but how do you explain it sometimes works and sometimes it doesn't? Or in other words, do you have an actionable thing in mind by which we could fix this?
@danielkrajnik
That's what I'm seeing as well. Not that I can explain the difference...
@rusty-snake commented on GitHub (Sep 26, 2023):
https://github.com/netblue30/firejail/issues/5903#issuecomment-1735423058 proper escaping with a backslash.
@ghost commented on GitHub (Sep 26, 2023):
That's already the case:
72edd9667b/src/man/firejail.1.in (L3116)@danielkrajnik commented on GitHub (Sep 26, 2023):
I've just tried logging out of X11 and logging back into Wayland and it still worked (hyphens were again correctly copied as hex
2d). Both on KDE Plasma. Sorry, not sure what's caused it before.@kmk3 commented on GitHub (Sep 26, 2023):
I can confirm that this was a problem when the issue was opened, though I can't
immediately reproduce it now either with man-db 2.11.2-1 on Artix.
I also had attempted a regex to fix this, but I didn't finish it.
This is what I had written (the examples are current):
GNU man ("man-db" package on Arch Linux) converts
-(hyphen-minus) intoe28090in the output, unless it's escaped as\-in the source and currentlyonly the first ones are escaped in the man pages, such as in
\-\-writable-run-user(it should be\-\-writable\-run\-user):Most/all options are unfortunately also half-escaped:
Note that mandoc does not convert them, so this seems to be a GNU-specific
thing.
@vinc17fr commented on GitHub (Sep 26, 2023):
Here I can see
The first two are properly escaped, so that they appear correctly in the man page. The other two are not escaped, so that they appear as U+2010 HYPHEN in the man page. This confirms the issue.
@vinc17fr commented on GitHub (Sep 27, 2023):
This actually comes from a recent change in
groff. See the discussion in Debian bug 1041731.@netblue30 commented on GitHub (Jan 8, 2026):
Fixed, thanks for the bug.
e256efe645