Commit Graph

9614 Commits

Author SHA1 Message Date
Adriaan de Groot
344948b5ab Modules: clean up QProcess (part 1) 2021-11-02 23:46:26 +01:00
Adriaan de Groot
2088502e57 [libcalamares] Don't use QProcess directly outside of Runner 2021-11-02 23:46:26 +01:00
Adriaan de Groot
57c174c37f [libcalamares] Clean up QProcess includes 2021-11-02 23:46:26 +01:00
Adriaan de Groot
5c82cb32ab [libcalamares] Expand tests to show last-output-line 2021-11-02 23:20:22 +01:00
Adriaan de Groot
aa315c0696 [libcalamares] Handle last-output-line without newline 2021-11-02 22:58:41 +01:00
Adriaan de Groot
0a339a5402 [libcalamares] Test Runner output-processing 2021-11-02 22:55:41 +01:00
Adriaan de Groot
953b899f75 [libcalamares] Allow Runner instances to collect output 2021-11-02 22:50:13 +01:00
Adriaan de Groot
870009e815 [libcalamares] Replace runCommand internals by Runner 2021-11-02 22:27:33 +01:00
Adriaan de Groot
89824a9e0d [libcalamares] Fix up Runner (as a replacement for current system code) 2021-11-02 22:27:33 +01:00
Adriaan de Groot
24ca64deac [libcalamares] Chase moved redacted-logging 2021-11-02 22:27:33 +01:00
Adriaan de Groot
85debfc69b [libcalamares] Add Redacted logging
- this was an internal class for logging commands, let's lift
  it up to the Logger framework where it might be more generally
  useful (or not .. everything needs special-casing for actual
  redaction).
2021-11-02 22:27:33 +01:00
Adriaan de Groot
f0104af1c3 [libcalamares] Expand tests on Runner internals 2021-11-02 22:27:33 +01:00
Adriaan de Groot
e5fa58b890 [libcalamares] Add tests for relativeCangeDirectory() 2021-11-02 22:27:32 +01:00
Adriaan de Groot
0b943e801c [libcalamares] Begin implementing Runner
This copies a bunch of code from the System methods for running,
and then #if 0's them to get it to compile. Add some basic
directory-management.
2021-11-02 22:27:32 +01:00
Adriaan de Groot
b9dac6eef8 [libcalamares] Small step in implementation 2021-11-02 22:27:32 +01:00
Adriaan de Groot
e0fdde06c9 [libcalamares] Python API for callbacks from processes
This is an experiment in Python API that will allow a callback
function in the Python module to be called for each output line.
It builds on the run-a-process extensions that are being built
simultaneously.
2021-11-02 22:27:32 +01:00
Adriaan de Groot
2de09d4001 [libcalamares] Start refactor of running-a-process support
The background idea is that, while CalamaresUtils::System::runCommand()
is a useful general API, it is
- still missing flexibility
- lacking a way to process output from the command "as it happens"

Waiting until the process ends, and then reading all stdout, is
inconvenient for processes that produce a **lot** of output,
and also makes it impossible to report progress. One module
in calamares-extensions has its own run-a-process implementation
for reading output, and this branch aims to introduce something
similar into Calamares core.
2021-11-02 22:27:32 +01:00
Adriaan de Groot
a9a287fa59 Merge branch 'issue-1564' into calamares
FIXES #1564
FIXES #1817

Tested by doing an LVM installation from KDE Neon, as described
in #1817. Installation was successful, and machine booted
successfully afterwards.
2021-11-02 15:37:24 +01:00
Adriaan de Groot
b5dba9108c [partition] Check for LVs that will be formatted, don't close them
- when (manually) using an existing LV, it shouldn't be closed
  prior to formatting, since that kills the volume and then the
  path (/dev/myvg/mylv) no longer exists. Then creating the
  filesysytem on that device path fails.
2021-11-02 15:33:34 +01:00
Adriaan de Groot
7b45793b60 [partition] Allow exceptions when closing /dev/mapper
- some names should not be closed, like "control"
- allow a list of names to be added which should not be closed
2021-11-02 15:26:25 +01:00
Adriaan de Groot
1410157356 [partition] Simplify and document ClearMounts
- note that the job indiscriminately closes all LUKS and LV
- don't hang on to lists we don't need
2021-11-02 11:55:13 +01:00
Adriaan de Groot
0253977778 [partition] Coding style 2021-11-02 11:50:51 +01:00
Adriaan de Groot
ca4a187d1a [partition] Extract the get-PV-groups code to its own function
- get the list (once)
- move the lambda to a named function for readability
2021-11-02 11:18:14 +01:00
Adriaan de Groot
7fa02fd41c [partition] Extract the get-LVM-volumes code to its own function 2021-11-02 11:10:09 +01:00
Adriaan de Groot
2a1ec84c87 [partition] Don't hang on to pointer longer than needed 2021-11-02 11:03:10 +01:00
Adriaan de Groot
04b119b051 [partition] Crypto device-list needn't be a member, either 2021-11-02 00:25:37 +01:00
Adriaan de Groot
f49389a408 [partition] Fix logic errors in stringification of MessageAndPath 2021-11-02 00:09:52 +01:00
Adriaan de Groot
c322eaa430 [partition] Fix translation issues
- Strings were being used as logical values, and then logged
  (which should be in English) and also used in the UI (which
  should be localized). Replace with a MessageAndPath class,
  used only locally, that defers the translation until called-
  upon explicitly.
- Replace some VG stuff with similar calls to apply().
2021-11-01 23:59:39 +01:00
Adriaan de Groot
e56158f5b4 [partition] Generate partition paths with /dev/
Returning partition full-paths instead of only the block-device-name
simplifies later code -- which would prepend /dev/ to the block-
device-name and umount that.
2021-11-01 20:54:48 +01:00
Adriaan de Groot
6c2b2b0daa [partition] Factor out loops, document return values
- the tryX() functions weirdly return a string that is used for
  debug-logging. Document that. The untranslated string is
  later used for user-facing messages. Mark that as FIXME.
- factor out the loop-over-names-and-append to news, because that
  makes the overall story of what is happening hard to read.
- all calls to tryCryptoClose() called tryUnmount() first, so
  put that call inside tryCryptoClose(), so the interface is simpler.
2021-11-01 20:54:18 +01:00
Adriaan de Groot
0c84a87c67 [partition] Make internal methods static 2021-11-01 20:28:47 +01:00
Adriaan de Groot
105517fed7 [partition] Coding style 2021-11-01 20:24:47 +01:00
Adriaan de Groot
ac34cfadea [partition] Factor out finding the swap-partitions 2021-11-01 20:23:49 +01:00
Adriaan de Groot
3e58639a68 [partition] Improve logging in ClearMountsJob
- mark internal bits as static
- explain what is being looked-for

SEE #1817
SEE #1564
2021-11-01 16:44:28 +01:00
Adriaan de Groot
3f8078ea0f Changes: post-release housekeeping 2021-11-01 14:54:31 +01:00
Adriaan de Groot
218c1d9344 [fstab] Weaken the prescription against / in crypttab
FIXES #1811
2021-11-01 14:52:04 +01:00
Adriaan de Groot
0df288f647 [welcome] Improve logging of unsatisfied requirements
- improve descriptive-strings in logging ("set?" is not very
  meaningful)
- log only the unsatisfied entries, since the preceding
  log-message suggests that that is what is happening.
2021-11-01 14:24:50 +01:00
dalto
d0100afe02 Merge branch 'calamares' of github.com:dalto8/calamares into calamares 2021-10-30 14:09:17 -05:00
Adriaan de Groot
2faa791de4 Changes: avoid constant merge-conflicts by separating 3.2 changelog 2021-10-30 15:02:31 +02:00
Adriaan de Groot
f3a7f6cdef Changes: pre-release housekeeping 2021-10-30 14:54:15 +02:00
Calamares CI
5e4028ec87 i18n: [calamares] Automatic merge of Transifex translations 2021-10-30 14:54:15 +02:00
Adriaan de Groot
cd56bab622
[partition] Merge pull request #1808 from dalto8/zfs-delete-fix
Fix for zfs partition deletion
2021-10-30 14:44:39 +02:00
dalto
13a2d25b24 Add separate functions for zfs 2021-10-29 16:54:09 -05:00
Adriaan de Groot
7f09cdca65 Changes: update description of this release 2021-10-29 16:55:17 +02:00
Adriaan de Groot
e9083ecabb [services-systemd] Add a schema file for the configuration 2021-10-29 16:41:03 +02:00
Adriaan de Groot
7aaefa42d1
Merge pull request #1815 from dalto8/timer
[services-systemd] Add support for timers
2021-10-29 14:29:50 +02:00
Adriaan de Groot
9e1b8622f2 [packagechooser] Replace smartClip() with just-do-it
QLabel allows scaling of the Pixmap by itself, and we have a
FixedAspectRatioLabel that scales a pixmap nicely. Use that.
(The new label type needed to be introduced to designer)

The screenshot should expand more agressively, so that it
does not get margins -- that just leave space around the
name and description -- when the window expands. Adjust some
of the stretching and layout in the UI file.
2021-10-29 13:15:07 +02:00
Calamares CI
65f5db29bb i18n: [python] Automatic merge of Transifex translations 2021-10-29 11:29:38 +02:00
Calamares CI
07e831a5bf i18n: [desktop] Automatic merge of Transifex translations 2021-10-29 11:29:38 +02:00
Calamares CI
5cea95d5eb i18n: [calamares] Automatic merge of Transifex translations 2021-10-29 11:29:38 +02:00