diff options
author | Karaoke Mugen CD | 2023-12-30 10:24:41 +0000 |
---|---|---|
committer | Karaoke Mugen CD | 2023-12-30 10:24:41 +0000 |
commit | e3c0371f15df422452b0761ff7ccc744b25c31d9 (patch) | |
tree | cc2523b06096fe27c0f15c2b9b4b98dda6c817ea | |
parent | 202308d04d3eae306ce62a5b61a302d5ee2a885c (diff) | |
download | aur-e3c0371f15df422452b0761ff7ccc744b25c31d9.tar.gz |
👷 Update CI
-rwxr-xr-x[-rw-r--r--] | .SRCINFO | 21 | ||||
-rwxr-xr-x | .gitignore | 15 | ||||
-rwxr-xr-x[-rw-r--r--] | PKGBUILD | 41 | ||||
-rwxr-xr-x[-rw-r--r--] | icon256.png | bin | 42780 -> 42780 bytes | |||
-rwxr-xr-x | install.sh | 28 | ||||
-rwxr-xr-x[-rw-r--r--] | karaokemugen.desktop | 2 | ||||
-rwxr-xr-x[-rw-r--r--] | karaokemugen.install | 0 |
7 files changed, 63 insertions, 44 deletions
diff --git a/.SRCINFO b/.SRCINFO index 38ebe72b0a89..be60656c5f35 100644..100755 --- a/.SRCINFO +++ b/.SRCINFO @@ -1,7 +1,7 @@ pkgbase = karaokemugen-git pkgdesc = Karaoke playlist manager/player app used in parties or events. - pkgver = 6.1.3.r086c8f9bd - pkgrel = 2 + pkgver = 4.1.10.r3713.g52d7e60c7 + pkgrel = 1 url = https://mugen.karaokes.moe/ install = karaokemugen.install arch = x86_64 @@ -10,19 +10,18 @@ pkgbase = karaokemugen-git makedepends = npm makedepends = typescript makedepends = yarn - makedepends = nodejs>=18 - makedepends = python - makedepends = jq + makedepends = nodejs depends = mpv depends = ffmpeg - depends = postgresql>=13 + depends = postgresql depends = electron + depends = patch optdepends = sudo: for using karaokemugen-install script provides = karaokemugen conflicts = karaokemugen - source = karaokemugen::git+https://gitlab.com/karaokemugen/karaokemugen-app.git#branch=master - source = karaokemugen-lib::git+https://gitlab.com/karaokemugen/lib.git - source = karaokemugen-avatars::git+https://gitlab.com/karaokemugen/medias/guest-avatars.git + source = karaokemugen::git+https://gitlab.com/karaokemugen/code/karaokemugen-app.git + source = karaokemugen-lib::git+https://gitlab.com/karaokemugen/code/lib.git + source = karaokemugen-guests::git+https://gitlab.com/karaokemugen/medias/guest-avatars.git source = install.sh source = run.sh source = icon256.png @@ -30,9 +29,9 @@ pkgbase = karaokemugen-git md5sums = SKIP md5sums = SKIP md5sums = SKIP - md5sums = e31ff0dc6707adce89c3221a7c9c3cb6 + md5sums = 74e8c0755a6e07cceb2895cef518660b md5sums = 55557823030b7824a85a55469e119cb4 md5sums = 5e9a33a42fef7572b7e0fa504c586f32 - md5sums = 10561eed906a5efeed427f90501b4f49 + md5sums = fae5d3e631e9ec8391655b31f586b74b pkgname = karaokemugen-git diff --git a/.gitignore b/.gitignore new file mode 100755 index 000000000000..47d0471f982f --- /dev/null +++ b/.gitignore @@ -0,0 +1,15 @@ +# from https://github.com/github/gitignore/blob/master/ArchLinuxPackages.gitignore +*.tar +*.tar.* +*.rpm +*.jar +*.exe +*.msi +*.zip +*.tgz +*.zst +*.log +*.log.* +*.sig + +*/
\ No newline at end of file diff --git a/PKGBUILD b/PKGBUILD index 5e0b4ca5d1c0..4a82e15e1ba0 100644..100755 --- a/PKGBUILD +++ b/PKGBUILD @@ -1,14 +1,14 @@ # Maintainer: leonekmi <usingarchbtw@leonekmi.fr> pkgname=karaokemugen-git -pkgver=6.1.3.r086c8f9bd -pkgrel=2 +pkgver=4.1.10.r3713.g52d7e60c7 +pkgrel=1 pkgdesc="Karaoke playlist manager/player app used in parties or events." arch=('x86_64') url="https://mugen.karaokes.moe/" license=('MIT') groups=() -depends=('mpv' 'ffmpeg' 'postgresql>=13' 'electron') -makedepends=('git' 'npm' 'typescript' 'yarn' 'nodejs>=18' 'python' 'jq') +depends=('mpv' 'ffmpeg' 'postgresql' 'electron' 'patch') +makedepends=('git' 'npm' 'typescript' 'yarn' 'nodejs') optdepends=('sudo: for using karaokemugen-install script') provides=("${pkgname%-git}") conflicts=("${pkgname%-git}") @@ -16,9 +16,9 @@ replaces=() backup=() options=() install=${pkgname%-git}.install -source=('karaokemugen::git+https://gitlab.com/karaokemugen/karaokemugen-app.git#branch=master' - 'karaokemugen-lib::git+https://gitlab.com/karaokemugen/lib.git' - 'karaokemugen-avatars::git+https://gitlab.com/karaokemugen/medias/guest-avatars.git' +source=("${pkgname%-git}::git+https://gitlab.com/karaokemugen/code/karaokemugen-app.git" + "${pkgname%-git}-lib::git+https://gitlab.com/karaokemugen/code/lib.git" + "${pkgname%-git}-guests::git+https://gitlab.com/karaokemugen/medias/guest-avatars.git" 'install.sh' 'run.sh' 'icon256.png' @@ -27,45 +27,43 @@ noextract=() md5sums=('SKIP' 'SKIP' 'SKIP' - 'e31ff0dc6707adce89c3221a7c9c3cb6' + '74e8c0755a6e07cceb2895cef518660b' '55557823030b7824a85a55469e119cb4' '5e9a33a42fef7572b7e0fa504c586f32' - '10561eed906a5efeed427f90501b4f49') + 'fae5d3e631e9ec8391655b31f586b74b') # Please refer to the 'USING VCS SOURCES' section of the PKGBUILD man page for # a description of each element in the source array. pkgver() { cd "$srcdir/${pkgname%-git}" - echo "$(jq -r .version package.json | sed -e 's/-master//g').r$(git rev-parse --short origin/master)" + # Git, tags available + git describe --long --tags | sed -e 's/^v//' -e 's/\([^-]*-g\)/r\1/;s/-/./g' } prepare() { cd "$srcdir/${pkgname%-git}" git submodule init - git config submodule.src/lib.url $srcdir/${pkgname%-git}-lib - git config submodule.assets/guestAvatars.url $srcdir/${pkgname%-git}-avatars - git -c protocol.file.allow=always submodule update + git config submodule.src/lib.url "$srcdir/${pkgname%-git}-lib" + git config submodule.assets/guestAvatars.url "$srcdir/${pkgname%-git}-guests" + git submodule update } build() { cd "$srcdir/${pkgname%-git}" - # Prepare dependencies export HOME="$srcdir/$pkgname-home" export XDG_CACHE_HOME="$srcdir/$pkgname-cache" export npm_config_devdir="$srcdir/$pkgname-npm-dev" export npm_config_cache="$srcdir/$pkgname-npm-cache" - mkdir -p $HOME $XDG_CACHE_HOME $npm_config_devdir $npm_config_cache - yarn install --frozen-lockfile - yarn add --dev electron-builder - yarn installkmfrontend + yarn setup + # Build and package with electron-builder export NODE_ENV='production' + electronDist=$(dirname $(realpath $(which electron))) electronVer=$(electron --version | tail -c +2) - yarn build - yarn buildkmfrontend - yarn electron-builder --linux --x64 -c.electronDist=/usr/lib/electron -c.electronVersion=$electronVer --dir + + yarn packer } package() { @@ -74,6 +72,7 @@ package() { # Application itself install -dm755 "$pkgdir/usr/lib/${pkgname%-git}" cp -dr --no-preserve=ownership packages/linux-unpacked/resources/* "$pkgdir/usr/lib/${pkgname%-git}/" + install -dm 755 "$pkgdir/usr/lib/${pkgname%-git}/asar" chmod -R 755 "$pkgdir/usr/lib/${pkgname%-git}/" # License diff --git a/icon256.png b/icon256.png Binary files differindex 134c7b1f42f5..134c7b1f42f5 100644..100755 --- a/icon256.png +++ b/icon256.png diff --git a/install.sh b/install.sh index 24afa9b7d8f6..369425821232 100755 --- a/install.sh +++ b/install.sh @@ -26,15 +26,6 @@ check_postgres() { fi } -check_mugen() { - if [ -f "/usr/lib/karaokemugen/app.asar" ]; then - echo -e "${_COL_GREEN_}Karaoke Mugen is installed in /usr/lib/karaokemugen." - else - echo -e "${_COL_BRED_}Karaoke Mugen is not installed in /usr/lib/karaokemugen. Exiting." - exit 1 - fi -} - setup_postgres() { echo -e "${_BEGIN_}Creating the karaokemugen_app database..." # Create the DB for Mugen @@ -53,7 +44,6 @@ setup_postgres() { sudo -u postgres -g postgres -H -- psql -c "CREATE DATABASE karaokemugen_app ENCODING 'UTF8';" sudo -u postgres -g postgres -H -- psql -c "CREATE USER karaokemugen_app WITH ENCRYPTED PASSWORD 'musubi'; GRANT ALL PRIVILEGES ON DATABASE karaokemugen_app TO karaokemugen_app;" sudo -u postgres -g postgres -H -- psql -d karaokemugen_app -c "CREATE EXTENSION unaccent;" - sudo -u postgres -g postgres -H -- psql -d karaokemugen_app -c "CREATE EXTENSION pgcrypto;" echo -e "${_COL_GREEN_}karaokemugen_app database created!" } @@ -69,6 +59,23 @@ if [[ $(which tput > /dev/null 2>&1 && tput -T "${TERM}" colors || echo -n '0') _BEGIN_="${_COL_BRED_}-> ${_COL_BBLUE_}" fi +while getopts ":g" opt; do + case ${opt} in + g ) + #target=$OPTARG + echo -e "${_COL_YELLOW_}You may have to enter your sudo password" + add_user_to_group + echo -e "${_BEGIN_}Done! You need to restart your session to apply these changes." + exit 0 + ;; + \? ) + echo "Invalid option: $OPTARG" 1>&2 + exit 1 + ;; + esac +done +shift $((OPTIND -1)) + echo -e "${_BEGIN_}Welcome to the Karaoke Mugen installer!" echo -e "${_COL_YELLOW_}⚠️ You may have to enter your sudo password a couple times during this installation." echo -e "${_COL_YELLOW_}This script may not work if you tweaked your PostgreSQL configuration." @@ -78,7 +85,6 @@ sleep 5 echo -e "${_BEGIN_}Doing some initial checks..." check_postgres -check_mugen setup_postgres diff --git a/karaokemugen.desktop b/karaokemugen.desktop index 4aaa3d3da360..a89108205bde 100644..100755 --- a/karaokemugen.desktop +++ b/karaokemugen.desktop @@ -3,7 +3,7 @@ Encoding=UTF-8 Version=1.0 Name=Karaoke Mugen Comment=Karaoke playlist manager/player app used in parties or events. -Exec=karaokemugen +Exec=karaokemugen --ozone-platform-hint=auto Icon=karaokemugen Terminal=false Type=Application diff --git a/karaokemugen.install b/karaokemugen.install index 76aeede9d7cd..76aeede9d7cd 100644..100755 --- a/karaokemugen.install +++ b/karaokemugen.install |