Oliver Smith
36dd53f402
Run ruff check --fix (MR 2357)
...
Now that we have target-version = "py310" in [tool.ruff] in
pyproject.toml, ruff check complains about using typing.Optional and
typing.Union instead of newer syntax. Run the tool to fix it.
2024-07-16 00:26:35 +02:00
Hugo Osvaldo Barrera
f3f392ef66
Use simplified Python 3.8 syntax (MR 2327)
...
This commit was generated with:
ruff check --fix --extend-select=UP .
2024-06-23 19:13:52 +02:00
Hugo Osvaldo Barrera
e421bb2d41
Auto-format codebase with ruff (MR 2325)
...
See: https://gitlab.com/postmarketOS/pmbootstrap/-/issues/2324
Closes: https://gitlab.com/postmarketOS/pmbootstrap/-/merge_requests/2278
2024-06-23 15:40:13 +02:00
Robert Eckelmann
044d3b5a6a
pmb.*: various comment reformatting to assist with generating docs (MR 2266)
2024-05-14 14:36:22 +02:00
Newbyte
c6a8a2614d
pmb.config.sudo: Use type union compatible with Python 3.7
...
The Type | OtherType syntax for writing unions was introduced in Python
3.10. We want to support Python 3.7, so use an Optional type hint
instead which declares the same thing and is supported by 3.7.
Fixes: d31313f7
("Don't use 'sudo' when running as root")
Reviewed-by: Luca Weiss <luca@z3ntu.xyz>
Link: https://lists.sr.ht/~postmarketos/pmbootstrap-devel/%3C20230605063142.6843-1-newbyte@postmarketos.org%3E
2023-06-05 13:12:52 +02:00
Hugo Osvaldo Barrera
d31313f7dc
Don't use 'sudo' when running as root
...
This cancels the need to install and configure `sudo` or `doas` on
single-user installations (e.g.: a VM dedicated to running pmbootstrap).
Fixes: https://gitlab.com/postmarketOS/pmbootstrap/-/issues/2224
Reviewed-by: Oliver Smith <ollieparanoid@postmarketos.org>
Link: https://lists.sr.ht/~postmarketos/pmbootstrap-devel/%3C20230529203922.22161-1-hugo@whynothugo.nl%3E
2023-06-04 11:35:08 +02:00
Oliver Smith
9975d373b0
Bump copyright to 2023
2023-01-22 19:18:06 +01:00
Oliver Smith
6f6a3b0408
Happy new year 2022!
2022-01-02 22:39:14 +01:00
Anjandev Momi
c1407f921b
Use doas instead of sudo if installed (MR 2091)
...
Prefer using doas over sudo if both are installed. Let the user override
the sudo tool with PMB_SUDO.
2021-12-12 18:46:17 +01:00