Commit 22578f7 pompurin404
committed
1 parent 935b95b commit 22578f7 Copy full SHA for 22578f7
File tree 10 files changed +228
-0
lines changed
10 files changed +228
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : aur-updater
2
+ on :
3
+ push :
4
+ branches :
5
+ - master
6
+
7
+ jobs :
8
+ update :
9
+ runs-on : ubuntu-latest
10
+ steps :
11
+ - uses : actions/checkout@v4
12
+ - name : update version
13
+ if : startsWith(github.ref, 'refs/tags/v')
14
+ run : |
15
+ sed -i "s/pkgver=.*/pkgver=$(git describe --long 2>/dev/null | sed 's/\([^-]*-g\)/r\1/;s/-/./g' | tr -d 'v')/" aur/mihomo-party-git/PKGBUILD
16
+ - name : Publish AUR package
17
+ uses : KSXGitHub/github-actions-deploy-aur@v2.7.2
18
+ with :
19
+ pkgname : mihomo-party-git
20
+ pkgbuild : aur/mihomo-party-git/PKGBUILD
21
+ commit_username : pompurin404
22
+ commit_email : pompurin404@mihomo.party
23
+ ssh_private_key : ${{ secrets.PRIVATE_KEY }}
24
+ commit_message : Update AUR package
25
+ ssh_keyscan_types : rsa,ed25519
26
+ allow_empty_commits : false
Original file line number Diff line number Diff line change
1
+ pkgname=mihomo-party-bin
2
+ _pkgname=mihomo-party
3
+ pkgver=0.1.3
4
+ pkgrel=1
5
+ pkgdesc=" Another Mihomo GUI."
6
+ arch=(' x86_64' ' aarch64' )
7
+ url=" https://github.com/pompurin404/mihomo-party"
8
+ license=(' GPL3' )
9
+ conflicts=(" mihomo-party-git" ' mihomo-party' )
10
+ depends=(' gtk3' ' libnotify' ' nss' ' libxss' ' libxtst' ' xdg-utils' ' at-spi2-core' ' util-linux-libs' ' at-spi2-core' ' libsecret' )
11
+ optdepends=(' libappindicator-gtk3: Allow mihomo-party to extend a menu via Ayatana indicators in Unity, KDE or Systray (GTK+ 3 library).' )
12
+ makedepends=(' nodejs' ' pnpm' ' jq' ' libxcrypt-compat' )
13
+ install=$_pkgname .install
14
+ source_x86_64=(" ${_pkgname} -${pkgver} -x86_64.deb::${url} /releases/download/v${pkgver} /mihomo-party-linux-${pkgver} -amd64.deb" )
15
+ source_x86_64=(" ${_pkgname} -${pkgver} -aarch64.deb::${url} /releases/download/v${pkgver} /mihomo-party-linux-${pkgver} -arm64.deb" )
16
+ sha256sums_x86_64=(' b8d166f1134573336aaae1866d25262284b0cbabbf393684226aca0fd8d1bd83' )
17
+ sha256sums_aarch64=(' 8cd7398b8fc1cd70d41e386af9995cbddc1043d9018391c29f056f1435712a10' )
18
+
19
+ package () {
20
+ tar xpf data.tar.gz -C ${pkgdir}
21
+ chmod +x ${pkgdir} /opt/mihomo-party/mihomo-party
22
+ chmod +x ${pkgdir} /opt/mihomo-party/resources/sidecar/mihomo
23
+ chmod +x ${pkgdir} /opt/mihomo-party/resources/sidecar/mihomo-alpha
24
+ cd ${pkgdir} /../..
25
+ install -Dm755 " ${_pkgname} .sh" " ${pkgdir} /usr/bin/${_pkgname} "
26
+ sed -i ' 3s!/opt/mihomo-party/mihomo-party!mihomo-party!' " ${pkgdir} /usr/share/applications/${_pkgname} .desktop"
27
+
28
+ chown -R root:root ${pkgdir}
29
+ }
Original file line number Diff line number Diff line change
1
+ # Colored makepkg-like functions
2
+ note() {
3
+ printf "${_blue}==>${_yellow} NOTE:${_bold} %s${_all_off}\n" "$1"
4
+ }
5
+
6
+ _all_off="$(tput sgr0)"
7
+ _bold="${_all_off}$(tput bold)"
8
+ _blue="${_bold}$(tput setaf 4)"
9
+ _yellow="${_bold}$(tput setaf 3)"
10
+
11
+ post_install() {
12
+ note "Custom flags should be put directly in: ~/.config/mihomo-party-flags.conf"
13
+ note "The launcher is called: 'mihomo-party'"
14
+ }
Original file line number Diff line number Diff line change
1
+ #! /usr/bin/bash
2
+
3
+ XDG_CONFIG_HOME=${XDG_CONFIG_HOME:- ~/ .config}
4
+
5
+ # Allow users to override command-line options
6
+ if [[ -f " ${XDG_CONFIG_HOME} /mihomo-party-flags.conf" ]]; then
7
+ mapfile -t MIHOMO_PARTY_USER_FLAGS <<< " $(grep -v '^#' " ${XDG_CONFIG_HOME} /mihomo-party-flags.conf" )"
8
+ echo " User flags:" ${MIHOMO_PARTY_USER_FLAGS[@]}
9
+ fi
10
+
11
+ # Launch
12
+ exec /opt/mihomo-party/mihomo-party ${MIHOMO_PARTY_USER_FLAGS[@]} " $@ "
Original file line number Diff line number Diff line change
1
+ pkgname=mihomo-party-git
2
+ _pkgname=${pkgname% -git}
3
+ pkgver=0.1.3.r4.g935b95b
4
+ pkgrel=1
5
+ pkgdesc=" Another Mihomo GUI."
6
+ arch=(' x86_64' ' aarch64' )
7
+ url=" https://github.com/pompurin404/mihomo-party"
8
+ license=(' GPL3' )
9
+ conflicts=(" mihomo-party" ' mihomo-party-bin' )
10
+ depends=(' gtk3' ' libnotify' ' nss' ' libxss' ' libxtst' ' xdg-utils' ' at-spi2-core' ' util-linux-libs' ' at-spi2-core' ' libsecret' )
11
+ optdepends=(' libappindicator-gtk3: Allow mihomo-party to extend a menu via Ayatana indicators in Unity, KDE or Systray (GTK+ 3 library).' )
12
+ makedepends=(' nodejs' ' pnpm' ' jq' ' libxcrypt-compat' )
13
+ install=$_pkgname .install
14
+ source=(" git+$url .git" )
15
+ sha256sums=(" SKIP" )
16
+ options=(' !lto' )
17
+
18
+ pkgver () {
19
+ cd $srcdir /${_pkgname}
20
+ ( set -o pipefail
21
+ git describe --long 2> /dev/null | sed ' s/\([^-]*-g\)/r\1/;s/-/./g' | tr -d ' v' ||
22
+ printf " r%s.%s" " $( git rev-list --count HEAD) " " $( git rev-parse --short HEAD) "
23
+ )
24
+ }
25
+
26
+ prepare (){
27
+ cd $srcdir /${_pkgname}
28
+ pnpm install
29
+ }
30
+
31
+ build (){
32
+ cd $srcdir /${_pkgname}
33
+ pnpm build:linux deb
34
+ }
35
+
36
+ package () {
37
+ version = jq ' .version' | tr -d ' v"'
38
+ cd $srcdir /${_pkgname} /dist
39
+ bsdtar -xf mihomo-party-linux-${version} * .deb
40
+ bsdtar -xf data.tar.xz -C " ${pkgdir} /"
41
+ chmod +x ${pkgdir} /opt/mihomo-party/mihomo-party
42
+ chmod +x ${pkgdir} /opt/mihomo-party/resources/sidecar/mihomo
43
+ chmod +x ${pkgdir} /opt/mihomo-party/resources/sidecar/mihomo-alpha
44
+ cd ${pkgdir} /../..
45
+ # Launcher
46
+ install -Dm755 " ${_pkgname} .sh" " ${pkgdir} /usr/bin/${_pkgname} "
47
+
48
+ # Launcher Fix
49
+ sed -i ' 3s!/opt/mihomo-party/mihomo-party!mihomo-party!' " ${pkgdir} /usr/share/applications/${_pkgname} .desktop"
50
+
51
+ chown -R root:root ${pkgdir}
52
+ }
Original file line number Diff line number Diff line change
1
+ # Colored makepkg-like functions
2
+ note() {
3
+ printf "${_blue}==>${_yellow} NOTE:${_bold} %s${_all_off}\n" "$1"
4
+ }
5
+
6
+ _all_off="$(tput sgr0)"
7
+ _bold="${_all_off}$(tput bold)"
8
+ _blue="${_bold}$(tput setaf 4)"
9
+ _yellow="${_bold}$(tput setaf 3)"
10
+
11
+ post_install() {
12
+ note "Custom flags should be put directly in: ~/.config/mihomo-party-flags.conf"
13
+ note "The launcher is called: 'mihomo-party'"
14
+ }
Original file line number Diff line number Diff line change
1
+ #! /usr/bin/bash
2
+
3
+ XDG_CONFIG_HOME=${XDG_CONFIG_HOME:- ~/ .config}
4
+
5
+ # Allow users to override command-line options
6
+ if [[ -f " ${XDG_CONFIG_HOME} /mihomo-party-flags.conf" ]]; then
7
+ mapfile -t MIHOMO_PARTY_USER_FLAGS <<< " $(grep -v '^#' " ${XDG_CONFIG_HOME} /mihomo-party-flags.conf" )"
8
+ echo " User flags:" ${MIHOMO_PARTY_USER_FLAGS[@]}
9
+ fi
10
+
11
+ # Launch
12
+ exec /opt/mihomo-party/mihomo-party ${MIHOMO_PARTY_USER_FLAGS[@]} " $@ "
Original file line number Diff line number Diff line change
1
+ pkgname=mihomo-party
2
+ pkgver=0.1.3
3
+ pkgrel=1
4
+ pkgdesc=" Another Mihomo GUI."
5
+ arch=(' x86_64' ' aarch64' )
6
+ url=" https://github.com/pompurin404/mihomo-party"
7
+ license=(' GPL3' )
8
+ conflicts=(" mihomo-party-git" ' mihomo-party-bin' )
9
+ depends=(' gtk3' ' libnotify' ' nss' ' libxss' ' libxtst' ' xdg-utils' ' at-spi2-core' ' util-linux-libs' ' at-spi2-core' ' libsecret' )
10
+ optdepends=(' libappindicator-gtk3: Allow mihomo-party to extend a menu via Ayatana indicators in Unity, KDE or Systray (GTK+ 3 library).' )
11
+ makedepends=(' nodejs' ' pnpm' ' jq' ' libxcrypt-compat' )
12
+ install=$pkgname .install
13
+ source=(" ${pkgname} -${pkgver} .tar.gz::${url} /archive/refs/tags/v${pkgver} .tar.gz" )
14
+ sha256sums=(" 52d761e9432e17477acb8adb5744676df946476e0eb5210fee2b6d45f497f218" )
15
+ options=(' !lto' )
16
+
17
+ prepare (){
18
+ cd $srcdir /${pkgname}
19
+ pnpm install
20
+ }
21
+
22
+ build (){
23
+ cd $srcdir /${pkgname}
24
+ pnpm build:linux deb
25
+ }
26
+
27
+ package () {
28
+ version = jq ' .version' | tr -d ' v"'
29
+ cd $srcdir /${pkgname} /dist
30
+ bsdtar -xf mihomo-party-linux-${version} * .deb
31
+ bsdtar -xf data.tar.xz -C " ${pkgdir} /"
32
+ chmod +x ${pkgdir} /opt/mihomo-party/mihomo-party
33
+ chmod +x ${pkgdir} /opt/mihomo-party/resources/sidecar/mihomo
34
+ chmod +x ${pkgdir} /opt/mihomo-party/resources/sidecar/mihomo-alpha
35
+ cd ${pkgdir} /../..
36
+ # Launcher
37
+ install -Dm755 " ${pkgname} .sh" " ${pkgdir} /usr/bin/${pkgname} "
38
+
39
+ # Launcher Fix
40
+ sed -i ' 3s!/opt/mihomo-party/mihomo-party!mihomo-party!' " ${pkgdir} /usr/share/applications/${pkgname} .desktop"
41
+
42
+ chown -R root:root ${pkgdir}
43
+ }
Original file line number Diff line number Diff line change
1
+ # Colored makepkg-like functions
2
+ note() {
3
+ printf "${_blue}==>${_yellow} NOTE:${_bold} %s${_all_off}\n" "$1"
4
+ }
5
+
6
+ _all_off="$(tput sgr0)"
7
+ _bold="${_all_off}$(tput bold)"
8
+ _blue="${_bold}$(tput setaf 4)"
9
+ _yellow="${_bold}$(tput setaf 3)"
10
+
11
+ post_install() {
12
+ note "Custom flags should be put directly in: ~/.config/mihomo-party-flags.conf"
13
+ note "The launcher is called: 'mihomo-party'"
14
+ }
Original file line number Diff line number Diff line change
1
+ #! /usr/bin/bash
2
+
3
+ XDG_CONFIG_HOME=${XDG_CONFIG_HOME:- ~/ .config}
4
+
5
+ # Allow users to override command-line options
6
+ if [[ -f " ${XDG_CONFIG_HOME} /mihomo-party-flags.conf" ]]; then
7
+ mapfile -t MIHOMO_PARTY_USER_FLAGS <<< " $(grep -v '^#' " ${XDG_CONFIG_HOME} /mihomo-party-flags.conf" )"
8
+ echo " User flags:" ${MIHOMO_PARTY_USER_FLAGS[@]}
9
+ fi
10
+
11
+ # Launch
12
+ exec /opt/mihomo-party/mihomo-party ${MIHOMO_PARTY_USER_FLAGS[@]} " $@ "
You can’t perform that action at this time.
0 commit comments