Browse Source

Fix Linux Mint codename

bryan 1 month ago
parent
commit
0cf4cd4afe
1 changed files with 3 additions and 4 deletions
  1. 3 4
      installJRMC

+ 3 - 4
installJRMC

@@ -189,8 +189,9 @@ init() {
     esac
     esac
 
 
     # Match the MC repo to the system
     # Match the MC repo to the system
-    [[ $ID == debian || $ID == ubuntu ]] && [[ -n $VERSION_CODENAME ]] && MC_DEFAULT_REPO="$VERSION_CODENAME"
-
+    if [[ $ID == debian || $ID == ubuntu ]]; then
+        MC_DEFAULT_REPO=${UBUNTU_CODENAME:-${VERSION_CODENAME:-$MC_DEFAULT_REPO}}
+    fi
     # Change the repo for user-specified legacy versions
     # Change the repo for user-specified legacy versions
     if [[ -n $USER_MC_VERSION ]]; then
     if [[ -n $USER_MC_VERSION ]]; then
         case $MC_MVERSION in
         case $MC_MVERSION in
@@ -475,7 +476,6 @@ set_mc_version() {
     fi
     fi
 
 
     echo "Using MC version $MC_VERSION from the ${MC_REPO:-$MC_DEFAULT_REPO} repo (determined by $MC_VERSION_SOURCE)"
     echo "Using MC version $MC_VERSION from the ${MC_REPO:-$MC_DEFAULT_REPO} repo (determined by $MC_VERSION_SOURCE)"
-    [[ $MC_VERSION_SOURCE == "user input" ]] || echo "To override, use --mcversion"
     return 0
     return 0
 }
 }
 
 
@@ -1662,7 +1662,6 @@ update_self() {
 }
 }
 
 
 
 
-
 main() {
 main() {
     debug "Running: ${FUNCNAME[0]} $*"
     debug "Running: ${FUNCNAME[0]} $*"