Commit graph

40 commits

Author SHA1 Message Date
Eberhard Beilharz
12165d73bc
fix(linux): Fix logging
We can't initialize Sentry during module initialization because our
`initialize_sentry` logs some status info. Setting the logging level
later on is then a no-op, breaking verbose and very-verbose logging.

This change fixes this by putting Sentry initialization into a
separate method that gets called after we set the log level.

Also refactor some common code into methods that appear in all our
executables.
2023-07-19 19:47:28 +02:00
Eberhard Beilharz
1b63cf59b4
chore(linux): Address code review comments 2023-07-05 11:56:55 +02:00
Eberhard Beilharz
e02b1514da
refactor(linux): Some refactorings 2023-07-05 11:56:54 +02:00
Eberhard Beilharz
66461b7677
feat(linux): Remove message box if same kbd version already installed
We no longer ask the user if he tries to install a keyboard that is
already installed with the same version. The only time we ask is for
downgrades.

A similar change is implemented in `km-package-install` where we
changed the logic to match `install_window.py`. We now silently
install the new version unless it's a downgrade in which case we
output a error message and exit. This change also introduces the
`--force` parameter which allows to install the downgrade. For
upgrades or re-installing the same version it will cause an
uninstall of the current version first.
2023-07-05 11:56:54 +02:00
Kevin Schluensen
82ea071c63 bug(linux): JSON File missing after installation
Fixes #8017
2023-01-18 17:21:02 +01:00
Eberhard Beilharz
89a253b1ca
feat(linux): Enhance tab completion in km-package-install
This change adds tab completion for the bcp-47 parameter in
km-package-install.

Fixes #5361
2023-01-11 12:28:12 +01:00
Eberhard Beilharz
a4abcdb831
Merge pull request #7730 from keymanapp/fix/linux/7722_replaceSharedKeyboard
fix(linux): Fix installation if shared kbd already installed
2022-11-18 08:41:46 +01:00
Eberhard Beilharz
a2ce5e50d8
fix(linux): Output warning if keyboard already installed in shared
This change outputs a warning if the user tries to install a
keyboard (to his home directory) and the keyboard is already
installed in the shared area, and vice versa.
2022-11-17 16:45:11 +01:00
Eberhard Beilharz
5c63d58978
feat(linux): Add -l as short version of --bcp47 parameter 2022-11-17 10:23:11 +01:00
Eberhard Beilharz
fd6083fd43
feat(linux): Add optional bcp47 parameter to km-package-install
This change adds a `--bcp47 <TAG>` parameter to km-package-install.
This allows to specify a language tag which will be used to install
the keyboard for that language.

Closes #7725.
2022-11-16 16:00:32 +01:00
Eberhard Beilharz
1d5b169aca
fix(linux): Allow to install local kbd if shared installed
This is similar to PR #7730 but implements things for
km-package-install.
2022-11-16 15:59:39 +01:00
Eberhard Beilharz
b1d201a3d7
feat(linux): Replace deprecated distutils
Fixes #6955
2022-08-08 16:38:35 +02:00
Eberhard Beilharz
0944d83f97
chore(linux): Code cleanup
Some reformatting.
2022-07-15 20:44:47 +02:00
Eberhard Beilharz
3eb4b58a58
fix(linux): Remove tab completion warning
This is done by replacing the deprecated `imp` module.

Fixes #6227.
2022-04-11 16:30:22 +02:00
Eberhard Beilharz
e47ff34587
chore(linux): Improve message when updating to a newer version
When trying to install a keyboard with `km-package-install` and
the same version was already installed or a newer version was
available and would be installed we now output a simple message
instead of an error.
2022-02-23 17:03:00 +01:00
Eberhard Beilharz
96ae4387ef
fix(linux): Properly compare versions in km-package-install
This change will fix a bug with comparing version numbers with more
than two sections (e.g. '1.2.3').

Fixes #6182.
2022-02-22 20:03:49 +01:00
Eberhard Beilharz
31170e8f94 fix(linux): Fix stray [-vv] in man pages
Additionally, don't print the date in the footer. This often overlaps
with the program name and version.

Also print usage in addition to error if wrong arguments are given.

Fixes #6240.
2022-02-18 14:15:17 +07:00
Eberhard Beilharz
0b8e628812
chore(linux): Improve robustness
Don't crash if we encounter a corrupt file.
2022-01-28 18:37:55 +01:00
Eberhard Beilharz
685eaa6ffc
fix(linux): Don't crash if we lack permissions
Also deal with other file I/O related exceptions and report them
as warnings.

This fixes #6171.
2022-01-28 18:37:54 +01:00
Eberhard Beilharz
58742b1a46
fix(linux): Check for valid zip file in km-package-install as well 2021-08-16 11:03:23 +02:00
Eberhard Beilharz
4d70382cbb
docs(linux): Improve help texts 2021-06-30 18:12:28 +02:00
Eberhard Beilharz
ba0a329cfd
feat(linux): Use staging URLs for alpha version 2020-07-17 19:22:51 +02:00
Eberhard Beilharz
89f9a13236
refactor(linux): cleanup code
Some more code cleanup of issues detected by linter.
2020-06-25 17:04:30 +02:00
Darcy
2beb0aa8f6 Save ico/bmp files to png 2019-09-11 10:06:44 +07:00
glasseyes
ac51b174b7 use search API to get list of keyboards
gets lists of all languages
then gets new keyboards from each language
2018-12-04 17:11:02 +07:00
glasseyes
a701eb3615 find either package or first keyboard icons
improve differentiating packageID and keyboardID in code
2018-11-23 11:18:43 +07:00
glasseyes
27caf56ed0 [linux] make jenkins happy: km-package-install -h 2018-10-12 10:09:44 +07:00
glasseyes
9cfb638e6b [linux] use long version of args variable names
as the short ones don't exist when there is a long one
2018-10-08 17:04:00 +07:00
glasseyes
fce8c0161f [linux] alternative --x options for km scripts
add completion for km-kvk2ldml options
2018-10-08 13:25:03 +07:00
glasseyes
be0443c593 [linux] cope with lack of network
create empty file if nothing in cache and no network
get the file if network comes back
2018-10-08 10:34:41 +07:00
glasseyes
af0b3c4f03 [linux] doc tab completion caveats 2018-10-08 10:13:22 +07:00
glasseyes
99206d4da9 [linux] tab completion for km-package-install
and km-package-list-installed
install the km-package.bash completion script
  in the Debian package to /etc/bash_completion.d

km-package-get: doc change of download location
2018-10-06 15:37:38 +07:00
glasseyes
3319bf5b96 [linux] try_install_kmp inline function 2018-10-04 16:33:55 +07:00
glasseyes
991651f7cd [linux] WIP: install error handling
and restarting ibus after attempting to install keyboard to it
2018-10-04 13:43:34 +07:00
glasseyes
8922a24b12 [linux] shared install check base dir and keyman dir
i.e. e.g check /usr/local/share/keyman and if it doesn't exist
check /usr/local/share before creating it

fix a bad logging formatting
2018-09-24 18:43:12 +07:00
glasseyes
9d83348357 [linux] WIP: install to ~/.local/share/keyman by default 2018-09-20 09:37:02 +07:00
glasseyes
671360915f keyman-config: move imports to after args parse
so that -h can be run without dependencies installed
2018-09-15 17:49:28 +07:00
glasseyes
71ba022bcd missing logging import 2018-09-14 09:34:32 +07:00
glasseyes
51dcd4a33b [linux] use python logging module to control cl output
for all scripts
add option -v for info messages
-vv for debug messages

remove creation of test ldml output file
2018-09-12 17:14:05 +07:00
glasseyes
b87e2da501 linux: rename scripts to km-* from PR 893
remove generated man pages, regenerate in 'make deb'
2018-09-10 14:29:10 +07:00
Renamed from linux/keyman-config/install_kmp (Browse further)