mirror of
https://github.com/Dichgrem/Dwrt-build.git
synced 2025-12-18 14:41:59 -05:00
Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b150951529 | ||
|
|
d842d24605 | ||
|
|
816642fba6 | ||
|
|
e2bc8f73ea |
55
.github/workflows/build.yml
vendored
55
.github/workflows/build.yml
vendored
@@ -1,4 +1,4 @@
|
|||||||
name: Build Custom WRT
|
name: Build WRT
|
||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
@@ -9,11 +9,16 @@ on:
|
|||||||
default: "immortalwrt"
|
default: "immortalwrt"
|
||||||
type: choice
|
type: choice
|
||||||
options:
|
options:
|
||||||
|
- lede
|
||||||
- openwrt
|
- openwrt
|
||||||
- immortalwrt
|
- immortalwrt
|
||||||
- x-wrt
|
- immortalwrt-mt798x
|
||||||
- lienol
|
- immortalwrt-mt798x-6.6
|
||||||
- lede
|
tag:
|
||||||
|
description: "版本号"
|
||||||
|
required: false
|
||||||
|
default: "v24.10.3"
|
||||||
|
type: string
|
||||||
version_type:
|
version_type:
|
||||||
description: "版本类型"
|
description: "版本类型"
|
||||||
required: true
|
required: true
|
||||||
@@ -22,23 +27,13 @@ on:
|
|||||||
options:
|
options:
|
||||||
- "snapshot"
|
- "snapshot"
|
||||||
- "stable"
|
- "stable"
|
||||||
branch:
|
|
||||||
description: "snapshot-branch"
|
|
||||||
required: false
|
|
||||||
default: "master"
|
|
||||||
type: string
|
|
||||||
tag:
|
|
||||||
description: "stable-tag"
|
|
||||||
required: false
|
|
||||||
default: "v24.10.2"
|
|
||||||
type: string
|
|
||||||
config_path:
|
config_path:
|
||||||
description: "config 路径"
|
description: "配置文件路径"
|
||||||
required: true
|
required: true
|
||||||
default: "config/myconfig"
|
default: "config/myconfig"
|
||||||
type: string
|
type: string
|
||||||
threads:
|
threads:
|
||||||
description: "编译线程数(留空或填写 0 则自动使用 nproc)"
|
description: "编译线程数(填写 0 则使用 nproc)"
|
||||||
required: false
|
required: false
|
||||||
default: "0"
|
default: "0"
|
||||||
type: string
|
type: string
|
||||||
@@ -61,18 +56,20 @@ jobs:
|
|||||||
/opt/microsoft
|
/opt/microsoft
|
||||||
sudo apt-get clean
|
sudo apt-get clean
|
||||||
sudo rm -rf /var/lib/apt/lists/*
|
sudo rm -rf /var/lib/apt/lists/*
|
||||||
# 显示当前磁盘使用情况
|
|
||||||
echo "📊 磁盘使用情况:"
|
echo "📊 磁盘使用情况:"
|
||||||
df -h || true
|
df -h || true
|
||||||
|
|
||||||
- name: Determine Git ref
|
- name: Choose Wrt Version
|
||||||
id: refinfo
|
id: refinfo
|
||||||
run: |
|
run: |
|
||||||
if [ "${{ inputs.version_type }}" = "snapshot" ]; then
|
if [ "$VERSION_TYPE" = "snapshot" ]; then
|
||||||
echo "ref=${{ inputs.branch }}" >> $GITHUB_OUTPUT
|
echo "ref=master" >> "$GITHUB_OUTPUT"
|
||||||
else
|
else
|
||||||
echo "ref=${{ inputs.tag }}" >> $GITHUB_OUTPUT
|
echo "ref=$TAG" >> "$GITHUB_OUTPUT"
|
||||||
fi
|
fi
|
||||||
|
env:
|
||||||
|
VERSION_TYPE: ${{ inputs.version_type }}
|
||||||
|
TAG: ${{ inputs.tag }}
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
@@ -96,15 +93,15 @@ jobs:
|
|||||||
immortalwrt)
|
immortalwrt)
|
||||||
echo "url=https://github.com/immortalwrt/immortalwrt.git" >> $GITHUB_OUTPUT
|
echo "url=https://github.com/immortalwrt/immortalwrt.git" >> $GITHUB_OUTPUT
|
||||||
;;
|
;;
|
||||||
x-wrt)
|
immortalwrt-mt798x)
|
||||||
echo "url=https://github.com/x-wrt/x-wrt.git" >> $GITHUB_OUTPUT
|
echo "url=https://github.com/hanwckf/immortalwrt-mt798x.git" >> $GITHUB_OUTPUT
|
||||||
|
;;
|
||||||
|
immortalwrt-mt798x-6.6)
|
||||||
|
echo "url=https://github.com/padavanonly/immortalwrt-mt798x-6.6.git" >> $GITHUB_OUTPUT
|
||||||
;;
|
;;
|
||||||
openwrt)
|
openwrt)
|
||||||
echo "url=https://git.openwrt.org/openwrt/openwrt.git" >> $GITHUB_OUTPUT
|
echo "url=https://git.openwrt.org/openwrt/openwrt.git" >> $GITHUB_OUTPUT
|
||||||
;;
|
;;
|
||||||
lienol)
|
|
||||||
echo "url=https://github.com/Lienol/openwrt.git" >> $GITHUB_OUTPUT
|
|
||||||
;;
|
|
||||||
lede)
|
lede)
|
||||||
echo "url=https://github.com/coolsnowwolf/lede.git" >> $GITHUB_OUTPUT
|
echo "url=https://github.com/coolsnowwolf/lede.git" >> $GITHUB_OUTPUT
|
||||||
;;
|
;;
|
||||||
@@ -114,7 +111,7 @@ jobs:
|
|||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
- name: Clone repository
|
- name: Clone Wrt source
|
||||||
run: |
|
run: |
|
||||||
echo "📥 克隆 ${{ inputs.project }} 仓库"
|
echo "📥 克隆 ${{ inputs.project }} 仓库"
|
||||||
git clone "${{ steps.projectinfo.outputs.url }}" wrt
|
git clone "${{ steps.projectinfo.outputs.url }}" wrt
|
||||||
@@ -164,7 +161,7 @@ jobs:
|
|||||||
diff -u .config.before_oldconfig .config || true
|
diff -u .config.before_oldconfig .config || true
|
||||||
fi
|
fi
|
||||||
|
|
||||||
- name: Download source packages
|
- name: Download packages
|
||||||
working-directory: wrt
|
working-directory: wrt
|
||||||
run: |
|
run: |
|
||||||
echo "⬇️ 下载所有源码包(使用单线程 -j1 避免卡住)"
|
echo "⬇️ 下载所有源码包(使用单线程 -j1 避免卡住)"
|
||||||
@@ -227,4 +224,4 @@ jobs:
|
|||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: ${{ inputs.project }}-build-log
|
name: ${{ inputs.project }}-build-log
|
||||||
path: wrt/world_debug.log
|
path: wrt/world_debug.log
|
||||||
@@ -6,8 +6,9 @@ This is a Openwrt build workflows.
|
|||||||
|
|
||||||
| 名称 | URL | SHORT |
|
| 名称 | URL | SHORT |
|
||||||
|--------------|------------------------------------------------------------|--------------------------|
|
|--------------|------------------------------------------------------------|--------------------------|
|
||||||
| x-wrt | https://github.com/x-wrt/x-wrt.git | x-wrt/x-wrt |
|
|
||||||
| openwrt | https://git.openwrt.org/openwrt/openwrt.git | openwrt/openwrt |
|
|
||||||
| lienol | https://github.com/Lienol/openwrt.git | Lienol/openwrt |
|
|
||||||
| lede | https://github.com/coolsnowwolf/lede.git | coolsnowwolf/lede |
|
| lede | https://github.com/coolsnowwolf/lede.git | coolsnowwolf/lede |
|
||||||
|
| openwrt | https://git.openwrt.org/openwrt/openwrt.git | openwrt/openwrt |
|
||||||
| immortalwrt | https://github.com/immortalwrt/immortalwrt.git | immortalwrt/immortalwrt |
|
| immortalwrt | https://github.com/immortalwrt/immortalwrt.git | immortalwrt/immortalwrt |
|
||||||
|
| immortalwrt-mt798x | https://github.com/hanwckf/immortalwrt-mt798x.git | hanwckf/immortalwrt-mt798x |
|
||||||
|
| immortalwrt-mt798x-6.6 | https://github.com/padavanonly/immortalwrt-mt798x-6.6.git | padavanonly/immortalwrt-mt798x-6.6 |
|
||||||
|
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user