mirror of
https://github.com/xopenwrt/X-OpenWrt-New.git
synced 2026-09-18 08:20:11 +00:00
AutoBuild-Actions: 20211212 功能更新
2021/12/12 更新内容
1. 新增固件标签 Default_FLAG, 一键更新固件时会自动检测带该标签的固件版本, e.g. 若固件标签为 Full, 则更新固件时仅可以更新到固件名称中带 Full 标签的版本
补充: 用户自定义变量 Default_FLAG, 支持数字与字母的组合 [0-9a-zA-Z] 例如 [Full Lite Daily1 Test2], 不支持标点符号, 不能为空
当该值为 AUTO 时, 将自动从配置文件名称获取, 格式为 <TARGET_PROFILE>-<FLAG>, e.g. 配置文件名称为 [x86_64-Test 或 d-team_newifi-d2-Lite], 则标签分别为 [Test Lite]; 配置文件若为不规则命名或无标签例如 [x86_64 X86 NEWIFI-D2], 则标签自动设定为 Full
同时支持在手动编译时临时修改, 点击 Run workflow 后修改 固件名称后缀 [可选] 值即可, 优先级高于用户自定义变量 Default_FLAG
固件内支持标签的快速切换, 切换方法 autoupdate --flag <标签名>, 恢复默认 autoupdate --flag reset
2. AutoBuild_Function.sh Firmware_Diy 函数中新增 CONFIG_FILE TARGET_FLAG 等可调用变量
3. 新增一些设备支持 (也许, 我也不知道)
改动内容较大, 建议重新 Fork 本仓库
This commit is contained in:
@@ -12,11 +12,14 @@ on:
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
Tempoary_IP:
|
||||
description: '临时修改 IP 地址 [可选]'
|
||||
description: '固件 IP 地址 [可选]'
|
||||
default: ''
|
||||
Tempoary_CONFIG:
|
||||
description: '配置文件 [可选]'
|
||||
default: ''
|
||||
Tempoary_FLAG:
|
||||
description: '固件名称后缀 [可选]'
|
||||
default: ''
|
||||
### 结束
|
||||
|
||||
#push:
|
||||
@@ -87,8 +90,16 @@ jobs:
|
||||
fi
|
||||
if [ -n "${{ github.event.inputs.Tempoary_IP }}" ]
|
||||
then
|
||||
echo "IP: [${{ github.event.inputs.Tempoary_IP }}]"
|
||||
echo "Tempoary_IP=${{ github.event.inputs.Tempoary_IP }}" >> $GITHUB_ENV
|
||||
fi
|
||||
if [ -n "${{ github.event.inputs.Tempoary_FLAG }}" ]
|
||||
then
|
||||
echo "FLAG: [${{ github.event.inputs.Tempoary_FLAG }}]"
|
||||
echo "Tempoary_FLAG=${{ github.event.inputs.Tempoary_FLAG }}" >> $GITHUB_ENV
|
||||
else
|
||||
echo "env Tempoary_FLAG is not detected !"
|
||||
fi
|
||||
REPO_URL="https://github.com/$(echo ${{ env.DEFAULT_SOURCE }} | cut -d \: -f 1)"
|
||||
REPO_BRANCH=$(echo ${{ env.DEFAULT_SOURCE }} | cut -d \: -f 2)
|
||||
echo "REPO_URL=$REPO_URL" >> $GITHUB_ENV
|
||||
|
||||
Reference in New Issue
Block a user