🐛 fix(bannerText): 修复文字动画在某些情况下会产生异常 #8
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
name: Build and Release | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
build: | |
runs-on: windows-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Set up VS | |
uses: seanmiddleditch/gha-setup-vsdevenv@master | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.12' | |
- name: Install setuptools | |
run: pip install setuptools | |
- name: Set up Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: '20' | |
- name: Install dependencies | |
run: npm install | |
- name: Rebuild dependencies | |
run: node_modules/.bin/electron-rebuild | |
- name: Build application | |
run: npm run build | |
- name: Delete release | |
uses: cb80/delrel@latest | |
with: | |
tag: 'latest' | |
token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Create release | |
id: create_release | |
uses: actions/create-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: latest | |
release_name: Latest Release | |
body: | | |
- 点击下方 `ElectronClassSchedule.zip` 即可下载,下载完成后请先解压再运行 | |
- 若下载过慢可使用第三方代理下载 [【点我下载】Win7_Win8_ElectronClassSchedule.zip](https://mirror.ghproxy.com/?q=https%3A%2F%2Fgithub.com%2Fdaizihan233%2FElectronClassSchedule%2Freleases%2Fdownload%2Flatest%2FWin7_Win8_ElectronClassSchedule.zip) | |
- 若下载过慢可使用第三方代理下载 [【点我下载】Win10_Win11_ElectronClassSchedule.zip](https://mirror.ghproxy.com/?q=https%3A%2F%2Fgithub.com%2Fdaizihan233%2FElectronClassSchedule%2Freleases%2Fdownload%2Flatest%2FWin10_Win11_ElectronClassSchedule.zip) | |
- 推荐使用VSCode编辑配置文件 [【点我下载】Visual Studio Code](https://lsw-fast.lenovo.com.cn/appstore/apps/4970-2024-03-01100059-1709258459745.exe) | |
draft: false | |
prerelease: false | |
- name: Pack folder to zip | |
uses: thedoctor0/zip-release@0.7.5 | |
with: | |
type: 'zip' | |
filename: 'release.zip' | |
directory: './out/classSchedule-win32-x64' | |
- name: Upload release asset | |
id: upload-release-asset | |
uses: actions/upload-release-asset@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
upload_url: ${{ steps.create_release.outputs.upload_url }} | |
asset_path: ./out/classSchedule-win32-x64/release.zip | |
asset_name: Win10_Win11_ElectronClassSchedule.zip | |
asset_content_type: application/zip | |
- name: Install specific Electron version | |
run: npm install electron@22.3.27 | |
- name: Rebuild dependencies for specific Electron version | |
run: node_modules/.bin/electron-rebuild | |
- name: Build application with specific Electron version | |
run: npm run build | |
- name: Pack folder to zip for specific Electron version | |
uses: thedoctor0/zip-release@0.7.5 | |
with: | |
type: 'zip' | |
filename: 'release-electron-22.3.27.zip' | |
directory: './out/classSchedule-win32-x64' | |
- name: Upload release asset for specific Electron version | |
uses: actions/upload-release-asset@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
upload_url: ${{ steps.create_release.outputs.upload_url }} | |
asset_path: ./out/classSchedule-win32-x64/release-electron-22.3.27.zip | |
asset_name: Win7_Win8_ElectronClassSchedule.zip | |
asset_content_type: application/zip |