Compare commits
10 Commits
60603c087d
...
870fc6eaed
| Author | SHA1 | Date | |
|---|---|---|---|
| 870fc6eaed | |||
| 2538cbe26a | |||
| 559c5eada5 | |||
| 4c586ff06a | |||
| 3694c7be13 | |||
| 21c3cf49d4 | |||
| aa6a0cc7f2 | |||
| c474ce4eb7 | |||
| 91c6f80961 | |||
| 5399276643 |
1
.gitignore
vendored
1
.gitignore
vendored
@@ -1,3 +1,4 @@
|
|||||||
.old/
|
.old/
|
||||||
.vscode/
|
.vscode/
|
||||||
README.bbcode
|
README.bbcode
|
||||||
|
installJRMC.zip
|
||||||
|
|||||||
28
installJRMC
28
installJRMC
@@ -16,7 +16,7 @@
|
|||||||
|
|
||||||
shopt -s extglob
|
shopt -s extglob
|
||||||
|
|
||||||
declare -g SCRIPT_VERSION="1.3.3"
|
declare -g SCRIPT_VERSION="1.3.4"
|
||||||
declare -g BOARD_URL="https://yabb.jriver.com/interact/index.php/board,86.0.html" # MC33
|
declare -g BOARD_URL="https://yabb.jriver.com/interact/index.php/board,86.0.html" # MC33
|
||||||
declare -g MC_VERSION="33.0.20" # Do find all replace
|
declare -g MC_VERSION="33.0.20" # Do find all replace
|
||||||
declare -g MC_DEFAULT_REPO="bullseye" # should match the MC_VERSION
|
declare -g MC_DEFAULT_REPO="bullseye" # should match the MC_VERSION
|
||||||
@@ -131,7 +131,7 @@ execute() {
|
|||||||
init() {
|
init() {
|
||||||
debug "Running: ${FUNCNAME[0]}"
|
debug "Running: ${FUNCNAME[0]}"
|
||||||
|
|
||||||
declare -g ID RPM_MGR ARCH
|
declare -g ID RPM_MGR ARCH OS_NAME
|
||||||
declare -ga PKG_INSTALL PKG_REMOVE PKG_UPDATE PKG_QUERY
|
declare -ga PKG_INSTALL PKG_REMOVE PKG_UPDATE PKG_QUERY
|
||||||
|
|
||||||
echo "Starting installJRMC"
|
echo "Starting installJRMC"
|
||||||
@@ -147,6 +147,8 @@ init() {
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
OS_NAME="${NAME// /_}"
|
||||||
|
|
||||||
# Detect architecture and translate to MC convention
|
# Detect architecture and translate to MC convention
|
||||||
ARCH=$(uname -m)
|
ARCH=$(uname -m)
|
||||||
case $ARCH in
|
case $ARCH in
|
||||||
@@ -156,10 +158,6 @@ init() {
|
|||||||
|
|
||||||
debug "Detected host platform: $ID $VERSION_ID $ARCH"
|
debug "Detected host platform: $ID $VERSION_ID $ARCH"
|
||||||
|
|
||||||
# Set defaults
|
|
||||||
BUILD_TARGET="${BUILD_TARGET:-$ID}"
|
|
||||||
REPO_TARGET="${REPO_TARGET:-$ID}"
|
|
||||||
|
|
||||||
# Normalize ID and set distro-specific vars
|
# Normalize ID and set distro-specific vars
|
||||||
case $ID in
|
case $ID in
|
||||||
debian|arch) ;;
|
debian|arch) ;;
|
||||||
@@ -193,6 +191,10 @@ init() {
|
|||||||
fi
|
fi
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
# Set defaults
|
||||||
|
BUILD_TARGET="${BUILD_TARGET:-$ID}"
|
||||||
|
REPO_TARGET="${REPO_TARGET:-$ID}"
|
||||||
|
|
||||||
# Match the MC repo to the system
|
# Match the MC repo to the system
|
||||||
if [[ $ID == debian || $ID == ubuntu ]]; then
|
if [[ $ID == debian || $ID == ubuntu ]]; then
|
||||||
MC_DEFAULT_REPO=${UBUNTU_CODENAME:-${VERSION_CODENAME:-$MC_DEFAULT_REPO}}
|
MC_DEFAULT_REPO=${UBUNTU_CODENAME:-${VERSION_CODENAME:-$MC_DEFAULT_REPO}}
|
||||||
@@ -678,7 +680,7 @@ acquire_deb() {
|
|||||||
for repo in "${repos[@]}"; do
|
for repo in "${repos[@]}"; do
|
||||||
echo "Checking $repo for DEB package"
|
echo "Checking $repo for DEB package"
|
||||||
if execute wget --quiet --output-document "$MC_DEB" "$repo"; then
|
if execute wget --quiet --output-document "$MC_DEB" "$repo"; then
|
||||||
echo "Found!"
|
echo "Found"
|
||||||
break
|
break
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
@@ -1669,12 +1671,10 @@ main() {
|
|||||||
debug "Running: ${FUNCNAME[0]} $*"
|
debug "Running: ${FUNCNAME[0]} $*"
|
||||||
|
|
||||||
parse_input "$@"
|
parse_input "$@"
|
||||||
|
|
||||||
init
|
init
|
||||||
|
|
||||||
debug "Debugging on"
|
debug "Debugging on"
|
||||||
debug "installJRMC version: $SCRIPT_VERSION"
|
debug "installJRMC version: $SCRIPT_VERSION"
|
||||||
# ((DEBUG)) && declare -p
|
|
||||||
|
|
||||||
((SELF_UPDATE)) && update_self "$@"
|
((SELF_UPDATE)) && update_self "$@"
|
||||||
|
|
||||||
@@ -1711,16 +1711,26 @@ main() {
|
|||||||
install_package epel-release
|
install_package epel-release
|
||||||
fi
|
fi
|
||||||
if ! "${PKG_QUERY[@]}" rpmfusion-free-release &>/dev/null; then
|
if ! "${PKG_QUERY[@]}" rpmfusion-free-release &>/dev/null; then
|
||||||
|
echo "Installing the RPMFusion repository"
|
||||||
install_package --no-install-check \
|
install_package --no-install-check \
|
||||||
"https://download1.rpmfusion.org/free/el/rpmfusion-free-release-$VERSION_ID.noarch.rpm"
|
"https://download1.rpmfusion.org/free/el/rpmfusion-free-release-$VERSION_ID.noarch.rpm"
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
fedora)
|
fedora)
|
||||||
if ! "${PKG_QUERY[@]}" rpmfusion-free-release &>/dev/null; then
|
if ! "${PKG_QUERY[@]}" rpmfusion-free-release &>/dev/null; then
|
||||||
|
echo "Installing the RPMFusion repository"
|
||||||
install_package --no-install-check \
|
install_package --no-install-check \
|
||||||
"https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$VERSION_ID.noarch.rpm"
|
"https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$VERSION_ID.noarch.rpm"
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
|
suse)
|
||||||
|
# if ! zypper repos | grep -q "X11_XOrg"; then
|
||||||
|
# echo "Installing the X11 repository"
|
||||||
|
# execute sudo zypper --non-interactive --quiet addrepo \
|
||||||
|
# "https://download.opensuse.org/repositories/X11:/XOrg/$OS_NAME/X11:XOrg.repo"
|
||||||
|
# execute sudo zypper --non-interactive --quiet refresh
|
||||||
|
# fi
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
if (( REPO_INSTALL_SWITCH )); then
|
if (( REPO_INSTALL_SWITCH )); then
|
||||||
|
|||||||
Reference in New Issue
Block a user