- the strange construction of Helper and treating it as a singleton
can be factored out into a separate singleton-handling instance()
function. The Helper should never be destroyed.
- when a single function does more logging, it generally marks
those as subsequent debug-messages (with Continuation, or SubEntry)
and we don't need to print funcinfo for those, since it was already
printed the first time.
- When a Python module calls utils.debug(), there's no point
in logging the C++ funcinfo that passes the parameters on;
don't use cDebug() with its attendant magic.
- Warnings, errors, don't get funcinfo, but regular cDebug()
calls do. Other special-cases, like calling Logger::CDebug()
constructor explicitly, don't get funcinfo either.
FIXES#1328
- Allow logging any QList type (needs explicit call in usage).
- Add a DebugList inheriting from DebugListT to keep existing
code that logs QStringLists.
- For Calamares 3.3, consider using C++17 and class template deduction.
- The manpage for umount says that -R can only be used with
a mount point (e.g. /usr/local) and not a device name;
this makes sense because a device might be mounted in multiple
locations, but the mountpoint (and things mounted under it) lives
in the filesystem tree.
- Existing code tried to unmount -R the device, not the mount point,
and so always failed; leaving things mounted that shouldn't.
- because mount() returns an exit code, and 0 is "success",
the if (!code) was backwards: when mounting succeeded, the
TemporaryMount object thought it failed.
- This leads to temp-mounts being left *all over* the place
from os-prober and fstab-handling.
- See editorial in the code-comment. Still need to test that
chroot(8) doesn't need a full path, otherwise this will
go to /usr/bin/env udevadm to force lookup (redundantly
if not in a chroot)
- Unconditionally **not** overwriting the target file isn't an option:
writing hostname, for instance, expects that to be done even
if `/etc/hostname` already exists on the target filesystem.
- Allow TranslatedString to get a context parameter; if it has
one, it will try to use the regular tr()-infrastructure
**as fallback** for the translations from the config file itself.
- This makes it possible to offer -- and translate -- some "standard"
phrases in the module, while allowing the config file the knob
to change strings. Using one of the standard strings gets translations
for "free", while introducing something entirely new means sourcing
translations for it as well.
- Different libraries should have different EXPORTs, so that
you can IMPORT one while building the other. Reported (and
kindly explained) by Kevin Kofler.
- Stick to one header file, though.
While here, update copyright on file.
- Let's just have one header definining export- and visibility-
macros for Calamares. They are still selected based on the
export flags (*_PRO), just defined in one header instead of two.
- If the test failed, you'd get a cryptic message like
FAIL! : NetworkTests::testPing() 'r' returned FALSE. ()
So rename the variable so the failure mode is more obvious.
(Could have used QVERIFY2() instead, this is simpler)
Introduces a "partitioning service" into libcalamares,
shuffles a bunch of things into it, tries to help out
with settling the system between partitioning actions.
- Take the Python wrapper for GlobalStorage out of the GlobalStorage.h
header and add it to PythonHelper instead, saving some work in
all the cases that only GS is interesting, not the Python bits.