Create r2modman module
This commit is contained in:
@@ -1,7 +0,0 @@
|
|||||||
modules:
|
|
||||||
- type: rpm-ostree
|
|
||||||
optfix:
|
|
||||||
- r2modman
|
|
||||||
- type: script
|
|
||||||
scripts:
|
|
||||||
- install-r2modman.sh
|
|
||||||
@@ -10,4 +10,5 @@ modules:
|
|||||||
- desktop-audio: /usr
|
- desktop-audio: /usr
|
||||||
- from-file: jp-apps.yml
|
- from-file: jp-apps.yml
|
||||||
- from-file: dev-packages.yml
|
- from-file: dev-packages.yml
|
||||||
# - from-file: r2modman.yml
|
- type: r2modman
|
||||||
|
version: 3.1.47
|
||||||
|
|||||||
15
config/scripts/install-r2modman.sh → modules/r2modman/r2modman.sh
Executable file → Normal file
15
config/scripts/install-r2modman.sh → modules/r2modman/r2modman.sh
Executable file → Normal file
@@ -1,17 +1,18 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
set -xeuo pipefail
|
set -euo pipefail
|
||||||
|
|
||||||
# Fetch the latest tag from the GitHub repository
|
VERSION=$(echo $1 | jq -r .version)
|
||||||
LATEST_TAG=$(curl -s https://api.github.com/repos/ebkr/r2modmanPlus/tags | jq -r '.[0].name')
|
|
||||||
|
|
||||||
# Extract the version number from the tag
|
echo "Installing R2modman Plus v${VERSION}"
|
||||||
VERSION=${LATEST_TAG#v}
|
|
||||||
|
|
||||||
echo "Latest version is $VERSION"
|
|
||||||
|
|
||||||
# Download the latest version of the r2modman package
|
# Download the latest version of the r2modman package
|
||||||
curl -L0 https://github.com/ebkr/r2modmanPlus/releases/download/v${VERSION}/r2modman-${VERSION}.x86_64.rpm -o r2modman-${VERSION}.x86_64.rpm
|
curl -L0 https://github.com/ebkr/r2modmanPlus/releases/download/v${VERSION}/r2modman-${VERSION}.x86_64.rpm -o r2modman-${VERSION}.x86_64.rpm
|
||||||
|
|
||||||
|
mkdir -p "/var/opt"
|
||||||
|
ln -s "/var/opt" "/opt"
|
||||||
|
mkdir -p "/usr/lib/opt/r2modman"
|
||||||
|
ln -s "../../usr/lib/opt/r2modman" "/var/opt/r2modman"
|
||||||
# Install the downloaded package
|
# Install the downloaded package
|
||||||
rpm-ostree install r2modman-${VERSION}.x86_64.rpm
|
rpm-ostree install r2modman-${VERSION}.x86_64.rpm
|
||||||
|
|
||||||
Reference in New Issue
Block a user