✨ feat: new #5
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
# This workflow will install Python dependencies, run tests and lint with a single version of Python | |
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python | |
name: Build and Release | |
on: | |
push: | |
branches: [ "main" ] | |
workflow_dispatch: # 允许手动触发 | |
permissions: | |
contents: write | |
jobs: | |
build-and-release: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python 3.10 | |
uses: actions/setup-python@v3 | |
with: | |
python-version: "3.10" | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt | |
- name: Get version | |
id: get_version | |
run: | | |
$version = "v1.0." + $env:GITHUB_RUN_NUMBER | |
echo "version=$version" >> $env:GITHUB_OUTPUT | |
- name: Build with PyInstaller | |
run: | | |
pyinstaller wifi_hotspot.spec | |
- name: Create Release ZIP | |
run: | | |
cd dist | |
7z a -tzip LiteWifi-${{ steps.get_version.outputs.version }}.zip "WiFi热点管理工具.exe" | |
- name: Create Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
tag_name: ${{ steps.get_version.outputs.version }} | |
name: LiteWifi ${{ steps.get_version.outputs.version }} | |
files: dist/LiteWifi-${{ steps.get_version.outputs.version }}.zip | |
body: | | |
## LiteWifi ${{ steps.get_version.outputs.version }} | |
### 更新内容 | |
- 自动构建发布于 ${{ github.event.head_commit.timestamp }} | |
- Commit: ${{ github.event.head_commit.message }} | |
### 使用说明 | |
1. 下载 LiteWifi-${{ steps.get_version.outputs.version }}.zip | |
2. 解压后以管理员身份运行 WiFi热点管理工具.exe | |
### 系统要求 | |
- Windows 10/11 | |
- 支持热点功能的网卡 | |
- 管理员权限 | |
### 主要功能 | |
- 创建/管理WiFi热点 | |
- 系统托盘支持 | |
- 记住配置信息 | |
- 密码显示/隐藏 | |
### 更新日志 | |
详见 [README.md](https://github.com/GalacticDevOps/LiteWifi/blob/main/README.md) | |
draft: false | |
prerelease: false | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: Upload Build Artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: LiteWifi-${{ steps.get_version.outputs.version }} | |
path: dist/WiFi热点管理工具.exe |