Git Product home page Git Product logo

autobuild-actions-template's Introduction

OpenWrt-Actions & One-key AutoUpdate

自用修改版软件包地址: AutoBuild-Packages

支持的 OpenWrt 源码: coolsnowwolf/ledeimmortalwrt/immortalwrtopenwrt/openwrtlienol/openwrt

🎈 提示: 文档中的 TARGET_PROFILE 为编译的设备名称(代号), 例如: d-team_newifi-d2asus_rt-acrh17x86_64

TARGET_PROFILE 本地获取方法如下:

① 执行make menuconfig, 进行设备选择后即可保存并退出

② 在源码目录执行egrep -o "CONFIG_TARGET.*DEVICE.*=y" .config | sed -r 's/.*DEVICE_(.*)=y/\1/'

grep 'TARGET_PROFILE' .config 均可获取 TARGET_PROFILE

🔔 为了你的账号安全, 请不要使用 SSH 连接 Github Action, .config配置以及固件定制等操作请务必在本地完成 🔔

一、定制固件(可选)

  1. Fork 该仓库, 并进入你自己的AutoBuild-Actions仓库, 下方所有操作都将在你的AutoBuild-Actions仓库下进行, 可以 Clone 到本地操作

    建议使用Github DesktopNotepad--进行编辑和提交操作 [Github Desktop] [Notepad--]

  2. 编辑Configs目录下的配置文件, 配置文件的命名一般为TARGET_PROFILE, 若配置文件不存在则需要在本地生成并上传

  3. 编辑.github/workflows/***.yml文件, 修改第 7 行 name:, 填写一个便于识别的名称 e.g. NEWIFI D2

  4. 编辑.github/workflows/***.yml文件, 修改第 32 行 CONFIG_FILE:, 填写你添加到Configs目录下的配置名称

  5. 根据需求编辑 Scripts/AutoBuild_DiyScript.sh

添加软件包、其他定制选项请在 Firmware_Diy() 函数中编写, Scripts目录下的其他文件无需修改

Scripts/AutoBuild_DiyScript.sh: Firmware_Diy_Core() 函数中的变量:

   Author 作者名称, AUTO: [自动识别]
   
   Author_URL 自定义作者网站或域名, AUTO: [自动识别]

   Default_Flag 固件标签 (名称后缀), 适用不同配置文件, AUTO: [自动识别]

   Default_IP 固件 IP 地址

   Default_Title 终端首页显示的额外信息

   Short_Fw_Date 简短的固件日期, true: [20210601]; false: [202106012359]

   x86_Full_Images 额外上传已检测到的 x86 虚拟磁盘镜像, true: [上传]; false: [不上传]
   
   Fw_MFormat 自定义固件格式, AUTO: [自动识别]

   Regex_Skip 输出固件时丢弃包含该内容的文件

   AutoBuild_Features 自动添加 AutoBuild 固件特性, 建议开启

   注: 禁用某功能请将变量值修改为 false, 开启则为 true

二、编译固件

手动编译 点击上方工具栏中的Actions选项, 在左侧选择设备,点击右方Run workflow再点击绿色按钮即可开始编译

Star 一键编译 编辑.github/workflows/***.yml文件, 删除注释#符号并提交修改, 单击或双击点亮右上角的 Star ⭐按钮即可一键编译

  #watch:
  #  types: [started]

定时编译 编辑.github/workflows/***.yml文件, 删除注释#符号, 并按需修改时间并提交修改 Corn 使用方法

  #schedule:
  #  - cron: 0 8 * * 5

临时修改固件 IP 地址 该功能仅在手动编译生效, 点击Run workflow后即可输入 IP 地址

使用其他 [.config] 配置文件 点击Run workflow后即可选择Configs目录下的配置文件名称

三、部署云端日志(可选)

  1. 下载本仓库中的 Update_Logs.json 到本地 (如果有)

  2. JSON 格式编辑本地的Update_Logs.json

  3. 手动上传修改后的Update_Logs.jsonGithub Release

  4. 在本地执行autoupdate --fw-log测试

使用一键更新固件脚本(可选)

首先需要打开TTYD 终端或者使用SSH, 按需输入下方指令:

常规更新固件: autoupdate

使用镜像加速更新固件: autoupdate -P

更新固件(不保留配置): autoupdate -n

强制刷写固件(危险): autoupdate -F

强制下载并刷写固件: autoupdate -f

更新脚本: autoupdate -x

打印运行日志: autoupdate --log

列出相关信息: autoupdate --list

检查运行环境: autoupdate --chk

查看脚本帮助: autoupdate --help

注意: 部分参数可一起使用, 例如 autoupdate -n -P -F --path /mnt/sda1

使用 tools 固件工具箱(可选)

打开TTYD 终端或者使用SSH, 执行指令tools即可启动固件工具箱

当前支持以下功能:

  • USB 扩展内部空间
  • Samba 相关设置
  • 打印端口占用详细列表
  • 打印所有硬盘信息
  • 网络检查 (基础网络 | Google 连接检测)
  • AutoBuild 固件环境修复
  • 系统信息监控
  • 打印在线设备列表

鸣谢

autobuild-actions-template's People

Contributors

hyy2001x avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.