forked from MetaCubeX/mihomo
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
6411dec
commit b7ee352
Showing
1 changed file
with
31 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -26,7 +26,7 @@ jobs: | |
# - { goos: linux, goarch: '386', output: '386' } | ||
# - { goos: linux, goarch: amd64, output: amd64 } | ||
- { goos: linux, goarch: amd64, goamd64: v3, output: amd64_v3 } | ||
- { goos: linux, goarch: arm64, output: arm64 } | ||
# - { goos: linux, goarch: arm64, output: arm64 } | ||
# - { goos: linux, goarch: arm, goarm: '7', output: armv7 } | ||
# - { goos: linux, goarch: mips, mips: hardfloat, output: mips-hardfloat } | ||
# - { goos: linux, goarch: mips, mips: softfloat, output: mips-softfloat } | ||
|
@@ -104,11 +104,37 @@ jobs: | |
gzip -c mihomo > mihomo-${GOOS}-${{matrix.jobs.output}}-${VERSION}.gz | ||
fi | ||
- name: Install FPM | ||
run: sudo apt-get install ruby ruby-dev rubygems build-essential && sudo gem install --no-document fpm | ||
|
||
- name: Create DEB package | ||
run: fpm -s dir -t deb -n mihomo -v ${{ github.ref }} --description "mihomo" ./mihomo=/usr/local/bin/mihomo | ||
if: ${{ matrix.jobs.goos == 'linux' }} | ||
run: | | ||
sudo apt-get install dpkg ruby ruby-dev rubygems build-essential && sudo gem install --no-document fpm | ||
mkdir -p mihomo/DEBIAN | ||
mkdir -p mihomo/usr/bin | ||
mkdir -p mihomo/etc/mihomo | ||
mkdir -p mihomo/usr/share/licenses/mihomo | ||
cp mihomo mihomo/usr/bin/ | ||
cp LICENSE mihomo/usr/share/licenses/mihomo/ | ||
cat > mihomo/etc/mihomo/config.yaml <<EOF | ||
mixed-port: 7890 | ||
external-controller: 127.0.0.1:9090 | ||
EOF | ||
cat > ./mihomo/DEBIAN/control <<EOF | ||
Package: mihomo | ||
Version: ${VERSION} | ||
Section: | ||
Priority: extra | ||
Architecture: ${{matrix.jobs.goarch}} | ||
Maintainer: MetaCubeX <[email protected]> | ||
Homepage: https://wiki.metacubex.one/ | ||
Description: The universal proxy platform. | ||
EOF | ||
dpkg-deb --build mihomo | ||
- name: Save version | ||
run: | | ||
|