Skip to content

Commit

Permalink
chore: 添加打包 action
Browse files Browse the repository at this point in the history
  • Loading branch information
shaddollxz committed Aug 28, 2023
1 parent 948f60f commit cea015c
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 3 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: build

on:
release:
types: [published]

jobs:
build:
name: build-and-release
runs-on: windows-latest

steps:
- name: Checkout
uses: actions/checkout@v2

- name: build
shell: pwsh
run: Invoke-Expression "$(pwd)/build/ahk2exe.exe /in $(pwd)/src/main.ahk /out $(pwd)/Keyput-Methoard-${{ github.event.release.tag_name }}.exe /icon $(pwd)/build/icon.ico /base $(pwd)/build/autohotkey64.exe"

- name: release
id: create_release
uses: softprops/action-gh-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
files: Keyput-Methoard-${{ github.event.release.tag_name }}.exe
token: ${{ secrets.GITHUB_TOKEN }}
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
# 我的自定义键盘
# keyput-methoard -- 我的自定义键入法

通过 [AHK](https://www.autohotkey.com) 实现的自定义键盘,灵感来源于[myKeyMap](https://github.com/xianyukang/MyKeymap),根据自己的需求重写的一套脚本,当前支持移动光标,快速输入符号

## 使用

下载 `autohotkey` ,双击加载[脚本]("/src/main.ahk"),或者编译为 exe 文件使用(推荐)
在 release 中选择对应版本的 exe 文件下载
或者克隆代码,在本地使用 `powershell``build` 目录中运行脚本 `build.ps1` 进行编译

## 说明

Expand Down
2 changes: 1 addition & 1 deletion build/build.ps1
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Invoke-Expression "./ahk2exe.exe /in ../src/main.ahk /out ../build/keyboard.exe /icon ../build/icon.ico /base ../build/autohotkey64.exe"
Invoke-Expression "./ahk2exe.exe /in ../src/main.ahk /out ../build/Keyput Methoard.exe /icon ../build/icon.ico /base ../build/autohotkey64.exe"

0 comments on commit cea015c

Please sign in to comment.