Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
tous
tails
Commits
b66f8718
Commit
b66f8718
authored
May 14, 2020
by
intrigeri
Browse files
Lint
parent
df9f0ead
Changes
1
Hide whitespace changes
Inline
Side-by-side
config/chroot_local-includes/usr/local/bin/tails-upgrade-frontend-wrapper
View file @
b66f8718
...
...
@@ -62,7 +62,8 @@ def main(*args):
"/bin/sh"
,
"-c"
,
"xhost +SI:localuser:{user};"
"sudo -u {user} /usr/local/bin/tails-upgrade-frontend {args};"
"xhost -SI:localuser:{user}"
.
format
(
user
=
RUN_AS_USER
,
args
=
" "
.
join
(
args
))
"xhost -SI:localuser:{user}"
.
format
(
user
=
RUN_AS_USER
,
args
=
" "
.
join
(
args
))
)
)
...
...
@@ -70,11 +71,12 @@ def main(*args):
def
error
(
msg
):
"""Show error and exit."""
cli_text
=
'{}: {} {}'
.
format
(
CMD
,
gettext
(
'error:'
),
msg
)
dialog_text
=
'''<b><big>{}</big></b>
\n\n
{}'''
.
format
(
gettext
(
'Error'
),
msg
)
dialog_text
=
'''<b><big>{}</big></b>
\n\n
{}'''
.
format
(
gettext
(
'Error'
),
msg
)
print
(
cli_text
,
file
=
sys
.
stderr
)
sh
.
zenity
(
'--error'
,
'--ellipsize'
,
'--title'
,
""
,
'--text'
,
dialog_text
,
_ok_code
=
[
0
,
1
,
5
])
_ok_code
=
[
0
,
1
,
5
])
sys
.
exit
(
1
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment