make_custom_pi_os
improvements
#191
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hello!
I have made some improvements to
make_custom_pi_os
after having some friction getting started on macos:Improve portability of make_custom_pi_os
which
to check forgsed
and use it if available:macos ships with BSD sed which doesn't support
-i
for in-placeediting
id -gn
insteadof hardcoding it to
${USER}
- macos doesn't create a groupwith the same name as the user by default
word splitting
set -euo pipefail
to make the script fail on errors andundefined variables, rather than silently continuing
progress bar when retrieving version info
before downloading it
Allow specifying variant when creating new custom os
Rather than just the hardcoded
raspios_lite_armhf
, users can now specifyraspios_lite_armhf
orraspios_lite_arm64
with-v/--variant
Guard against space / hyphen in the destination folder
This causes some pain, as the default module uses this directory name for creating variables.
If these characters are just disallowed, this pain goes away