Compare commits
2 Commits
f2d08bc3e6
...
df9c1ccbea
| Author | SHA1 | Date | |
|---|---|---|---|
| df9c1ccbea | |||
| d62f844371 |
16
installJRMC
16
installJRMC
@@ -21,7 +21,7 @@
|
|||||||
# shellcheck disable=SC2317
|
# shellcheck disable=SC2317
|
||||||
shopt -s extglob
|
shopt -s extglob
|
||||||
|
|
||||||
declare -g SCRIPT_VERSION="1.34.4-dev"
|
declare -g SCRIPT_VERSION="1.34.4"
|
||||||
declare -g MC_VERSION="34.0.42" # do find all replace (hardcoded fallback)
|
declare -g MC_VERSION="34.0.42" # do find all replace (hardcoded fallback)
|
||||||
declare -g MC_REPO="bookworm" # should match the MC_VERSION
|
declare -g MC_REPO="bookworm" # should match the MC_VERSION
|
||||||
declare -g BOARD_ID="89.0" # MC34 board ID for automatic version detection
|
declare -g BOARD_ID="89.0" # MC34 board ID for automatic version detection
|
||||||
@@ -252,7 +252,7 @@ init() {
|
|||||||
# Run the self-updater if enabled
|
# Run the self-updater if enabled
|
||||||
((SELF_UPDATE_SWITCH)) && update "$@"
|
((SELF_UPDATE_SWITCH)) && update "$@"
|
||||||
|
|
||||||
fix_permissions "${HOME:-"/home/$USER"}/.jriver" "$USER"
|
fix_permissions "$HOME/.jriver" "$USER"
|
||||||
|
|
||||||
# Get host information
|
# Get host information
|
||||||
[[ -f /etc/os-release ]] && source /etc/os-release
|
[[ -f /etc/os-release ]] && source /etc/os-release
|
||||||
@@ -1590,9 +1590,15 @@ service_jriver-createrepo() {
|
|||||||
fix_dotjriver_permissions() {
|
fix_dotjriver_permissions() {
|
||||||
debug "${FUNCNAME[0]}()"
|
debug "${FUNCNAME[0]}()"
|
||||||
|
|
||||||
# Ensure the user owns the .jriver directory
|
# Ensure the user owns their .jriver directory
|
||||||
[[ -d "$HOME/.jriver" ]] && execute sudo chown -R "$USER:$USER" "$HOME/.jriver"
|
if [[ -d "$HOME/.jriver" ]]; then
|
||||||
|
local owner
|
||||||
|
owner=$(stat -c '%U' "$HOME/.jriver")
|
||||||
|
if [[ "$owner" != "$USER" ]]; then
|
||||||
|
ask_ok "$USER does not currently own $HOME/.jriver, attempt fix?" &&
|
||||||
|
execute sudo chown -R "$USER:$USER" "$HOME/.jriver"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
# @description Completely uninstalls MC, services, and firewall rules
|
# @description Completely uninstalls MC, services, and firewall rules
|
||||||
|
|||||||
Reference in New Issue
Block a user