This is an automated email from the git hooks/post-receive script. x2go pushed a change to branch master in repository pyhoca-cli. from 2b50752 pyhoca/cli/frontend.py: Fix reference before assignment error in resume_session() method. Thanks to Randy Goldenberg for spotting this. (Fixes: #1445). new c804576 Fix typo in man page. new dd72855 pyhoca-cli: Print debug message before exiting pyhoca-cli. new 7e84ca4 pyhoca-cli: Add cmdline parameter --clipboard-mode. new 3633dc4 pyhoca-cli: Do input check on value passed in via the --link option. new 1b9745d pyhoca-cli: Add cmdline parameter --dpi. The 5 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "adds" were already present in the repository and have only been added to this reference. Summary of changes: man/man1/pyhoca-cli.1 | 8 +++++++- pyhoca-cli | 22 ++++++++++++++++++++++ pyhoca/cli/frontend.py | 2 ++ 3 files changed, 31 insertions(+), 1 deletion(-) -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/pyhoca-cli.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository pyhoca-cli. commit 7e84ca499f4b6b29ca7796886c7231be6353e87e Author: Mike Gabriel <mike.gabriel@das-netzwerkteam.de> Date: Thu Aug 19 16:11:42 2021 +0200 pyhoca-cli: Add cmdline parameter --clipboard-mode. --- man/man1/pyhoca-cli.1 | 3 +++ pyhoca-cli | 6 ++++++ pyhoca/cli/frontend.py | 1 + 3 files changed, 10 insertions(+) diff --git a/man/man1/pyhoca-cli.1 b/man/man1/pyhoca-cli.1 index 107de1b..03d382d 100644 --- a/man/man1/pyhoca-cli.1 +++ b/man/man1/pyhoca-cli.1 @@ -206,6 +206,9 @@ Enable Xinerama support for multi-head setups. Requires X2Go Server 4.1.0.0 (or \*(T<\fB\-q, \-\-link\fR \fI{modem|isdn|adsl|wan|lan}\fR\*(T> Link quality (default: 'adsl') .TP +\*(T<\fB\-C, \-\-clipboard\-mode\fR \fI{none|server|client|both}\fR\*(T> +Clipboard mode (default: \'both\' directions, other allowed values: \'none\' for no clipboard support, \'client\' to server copy+pasting only, \'server\' to client copy+pasting only) +.TP \*(T<\fB\-t, \-\-session\-type\fR \fI{desktop|application}\fR\*(T> Session type (default: 'application'). Note: there are also some auto-detection feature for the session type built into the code. diff --git a/pyhoca-cli b/pyhoca-cli index 3d02377..19f0263 100755 --- a/pyhoca-cli +++ b/pyhoca-cli @@ -193,6 +193,7 @@ nx_options = [ {'args':['--pack'], 'default': '16m-jpeg-9', 'help': 'compression methods (see below for possible values)', }, {'args':['--kbd-type'], 'default': 'auto', 'help': 'set Keyboard type (default: \'auto\', other allowed options: \'pc105/us\', \'pc105/de\', etc.)',}, {'args':['--kbd-layout'], 'default': 'null', 'help': 'use keyboard layout (default: \'null\', allowed options: \'de\', \'fr\', etc.)',}, + {'args':['-C', '--clipboard-mode'], 'default': 'both', 'help': 'configure clipboard mode (default: \'both\' directions, other allowed values: \'none\' for no clipboard support, \'client\' to server copy+pasting only, \'server\' to client copy+pasting only)',}, ] compat_options = [ {'args':['--port'], 'default': None, 'help': 'compatibility option, synonymous to --remote-ssh-port PORT', }, @@ -418,6 +419,11 @@ Possible values for the --pack NX option are: if a.kbd_type == 'auto': a.kbd_layout = 'null' + # input check for --clipboard-mode + a.clipboard_mode = a.clipboard_mode.lower() + if a.clipboard_mode not in ('none', 'both', 'client', 'server'): + runtime_error ("value for cmd line argument --clipboard-mode is not any of 'none', 'both', 'client' or 'server'", parser=p, exitcode=1) + # lightdm remote login magic takes place here if a.from_stdin: diff --git a/pyhoca/cli/frontend.py b/pyhoca/cli/frontend.py index 7551838..2609173 100644 --- a/pyhoca/cli/frontend.py +++ b/pyhoca/cli/frontend.py @@ -471,6 +471,7 @@ class PyHocaCLI(x2go.X2GoClient): share_local_folders=self.args.share_local_folders, allow_share_local_folders=allow_share_local_folders, forward_sshagent=self.args.forward_sshagent, + clipboard=self.args.clipboard_mode, cmd=self.args.command) def authenticate(self): -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/pyhoca-cli.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository pyhoca-cli. commit dd72855a78b27ede220a31988cffb004762d6b90 Author: Daniel Teichmann <daniel.teichmann@das-netzwerkteam.de> Date: Thu Aug 19 14:59:38 2021 +0200 pyhoca-cli: Print debug message before exiting pyhoca-cli. --- pyhoca-cli | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pyhoca-cli b/pyhoca-cli index 7dd9001..3d02377 100755 --- a/pyhoca-cli +++ b/pyhoca-cli @@ -441,9 +441,11 @@ if __name__ == '__main__': if not os.environ.get('DISPLAY'): logger('the display environment variable is unset, can\'t go on without a DISPLAY...', x2go.loglevel_ERROR, ) + logger('exiting pyhoca-cli now.', x2go.loglevel_DEBUG, ) sys.exit(1) elif not re.match("^.*:[0-9]+(|\.[0-9]+)$", os.environ.get('DISPLAY')): logger('the display environment variable\'s value is weird ({val}), can\'t go on with that...'.format(val=os.environ.get('DISPLAY')), x2go.loglevel_ERROR, ) + logger('exiting pyhoca-cli now.', x2go.loglevel_DEBUG, ) sys.exit(1) try: @@ -454,6 +456,7 @@ if __name__ == '__main__': thisPyHocaCLI.authenticate() thisPyHocaCLI.MainLoop() + logger('exiting pyhoca-cli now.', x2go.loglevel_DEBUG, ) sys.exit(0) except (KeyboardInterrupt, SystemExit) as e: -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/pyhoca-cli.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository pyhoca-cli. commit c804576fa673eafc59cc9c288ccdabce87b0a400 Author: Daniel Teichmann <daniel.teichmann@das-netzwerkteam.de> Date: Thu Aug 19 14:53:58 2021 +0200 Fix typo in man page. --- man/man1/pyhoca-cli.1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/man/man1/pyhoca-cli.1 b/man/man1/pyhoca-cli.1 index 9382166..107de1b 100644 --- a/man/man1/pyhoca-cli.1 +++ b/man/man1/pyhoca-cli.1 @@ -51,7 +51,7 @@ No output to stdout at all! Enable debugging output. .TP \*(T<\fB\-\-libdebug\fR\*(T> -Enable debugging code of the unterlying Python X2Go module. +Enable debugging code of the underlying Python X2Go module. .TP \*(T<\fB\-\-libdebug-sftpxfer\fR\*(T> Enable debugging code of Python X2Go's sFTP server code (very verbose, and it may even reveal promiscuous data). -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/pyhoca-cli.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository pyhoca-cli. commit 3633dc423ce1d38ec458a0dbef0c1d2717287806 Author: Mike Gabriel <mike.gabriel@das-netzwerkteam.de> Date: Thu Aug 19 16:20:44 2021 +0200 pyhoca-cli: Do input check on value passed in via the --link option. --- pyhoca-cli | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pyhoca-cli b/pyhoca-cli index 19f0263..8f9a061 100755 --- a/pyhoca-cli +++ b/pyhoca-cli @@ -419,6 +419,11 @@ Possible values for the --pack NX option are: if a.kbd_type == 'auto': a.kbd_layout = 'null' + # input check for --link + a.link = a.link.lower() + if a.link not in ('modem', 'isdn', 'adsl', 'wan','lan'): + runtime_error ("value for cmd line argument --link is not any of 'modem', 'isdn', 'adsl', 'wan' or 'lan'", parser=p, exitcode=1) + # input check for --clipboard-mode a.clipboard_mode = a.clipboard_mode.lower() if a.clipboard_mode not in ('none', 'both', 'client', 'server'): -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/pyhoca-cli.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository pyhoca-cli. commit 1b9745d80018d4b7c025e1776c3e9082c85cf4ef Author: Mike Gabriel <mike.gabriel@das-netzwerkteam.de> Date: Thu Aug 19 16:16:13 2021 +0200 pyhoca-cli: Add cmdline parameter --dpi. --- man/man1/pyhoca-cli.1 | 3 +++ pyhoca-cli | 8 ++++++++ pyhoca/cli/frontend.py | 1 + 3 files changed, 12 insertions(+) diff --git a/man/man1/pyhoca-cli.1 b/man/man1/pyhoca-cli.1 index 03d382d..aeba44c 100644 --- a/man/man1/pyhoca-cli.1 +++ b/man/man1/pyhoca-cli.1 @@ -200,6 +200,9 @@ NOT IMPLEMENTED YET: For SSH based X2Go Session Brokers. Full path to a valid SS \*(T<\fB\-g, \-\-geometry\fR \fI{<WIDTH>x<HEIGHT>|fullscreen|maximize}\fR\*(T> Screen geometry (default: '800x600'). .TP +\*(T<\fB\-\-dpi\fR \fI<DPI>\fR\*(T> +Launch X2Go session's Xserver with resolution <DPI> (in dots per inch). +.TP \*(T<\fB\-\-xinerama\fR\*(T> Enable Xinerama support for multi-head setups. Requires X2Go Server 4.1.0.0 (or newer). .TP diff --git a/pyhoca-cli b/pyhoca-cli index 8f9a061..1d5b072 100755 --- a/pyhoca-cli +++ b/pyhoca-cli @@ -159,6 +159,7 @@ x2go_options = [ {'args':['-l', '-u','--username'], 'default': None, 'help': 'username for the session (default: current user)', }, {'args':['--password'], 'default': None, 'help': 'user password for session authentication', }, {'args':['--force-password'], 'default': False, 'action': 'store_true', 'help': 'enforce username/password authentication', }, + {'args':['--dpi'], 'default': None, 'help': 'resolution (in dots per inch) to be used by the X2Go session\'s Xserver', }, {'args':['-p','--remote-ssh-port'], 'default': '22', 'help': 'remote SSH port (default: 22)', }, {'args':['-i', '-k','--ssh-privkey'], 'default': None, 'help': 'use file \'SSH_PRIVKEY\' as private key for the SSH connection (e.g. ~/.ssh/id_rsa)', }, {'args':['--add-to-known-hosts'], 'default': False, 'action': 'store_true', 'help': 'add RSA host key fingerprint to ~/.ssh/known_hosts if authenticity of server can\'t be established (default: not set)', }, @@ -424,6 +425,13 @@ Possible values for the --pack NX option are: if a.link not in ('modem', 'isdn', 'adsl', 'wan','lan'): runtime_error ("value for cmd line argument --link is not any of 'modem', 'isdn', 'adsl', 'wan' or 'lan'", parser=p, exitcode=1) + # input check for --dpi + try: + if int(a.dpi) < 20 or int(a.dpi) > 400: + runtime_error ("value for cmd line argument --dpi must be between 20 and 400", parser=p, exitcode=1) + except ValueError: + runtime_error ("value for cmd line argument --dpi must be an positive integer value between 20 and 400", parser=p, exitcode=1) + # input check for --clipboard-mode a.clipboard_mode = a.clipboard_mode.lower() if a.clipboard_mode not in ('none', 'both', 'client', 'server'): diff --git a/pyhoca/cli/frontend.py b/pyhoca/cli/frontend.py index 2609173..4cb5962 100644 --- a/pyhoca/cli/frontend.py +++ b/pyhoca/cli/frontend.py @@ -458,6 +458,7 @@ class PyHocaCLI(x2go.X2GoClient): profile_name = 'Pyhoca-Client_Session', session_type=self.args.session_type, link=self.args.link, + dpi=self.args.dpi, xinerama=self.args.xinerama, geometry=self.args.geometry, pack=self.args.pack, -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/pyhoca-cli.git