Skip to content

Commit d6cf79c

Browse files
committed
init
0 parents  commit d6cf79c

22 files changed

+2531
-0
lines changed

.cargo/config.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[build]
2+
target = "i686-pc-windows-msvc"

.gitattributes

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
* text eol=lf
2+
*.dll binary

.github/workflows/CI-build.yaml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: md5-CI-build
2+
3+
on:
4+
push:
5+
workflow_dispatch:
6+
7+
env:
8+
DLL_NAME: ukaing
9+
10+
jobs:
11+
build:
12+
if: ${{ !startsWith(github.ref, 'refs/tags/') }}
13+
runs-on: windows-latest
14+
steps:
15+
- uses: actions/checkout@v4
16+
- uses: actions-rs/toolchain@v1
17+
with:
18+
toolchain: stable
19+
- uses: actions/cache@v3
20+
with:
21+
path: |
22+
~/.cargo/bin/
23+
~/.cargo/registry/index/
24+
~/.cargo/registry/cache/
25+
~/.cargo/git/db/
26+
target/
27+
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
28+
- name: release-build
29+
run: |
30+
cargo build --release --target=i686-pc-windows-msvc
31+
Copy-Item -Force -Verbose .\target\i686-pc-windows-msvc\release\${{ env.DLL_NAME }}.dll .\
32+
shell: pwsh
33+
- name: disable auto crlf
34+
uses: steve02081504/disable-autocrlf@v1
35+
- name: updates build
36+
uses: Taromati2/ukagaka-mirror-md5-CI-build@v1
37+
with:
38+
no-push: true
39+
build-mode: other
40+
- name: git push
41+
# commit and push all changes at once to avoid error
42+
run: |
43+
git config --local user.email "calcium629@gmail.com"
44+
git config --local user.name "apxxxxxxe"
45+
git config --local core.safecrlf off
46+
git add .
47+
git status
48+
git commit -m "update md5 & dll" -a
49+
git pull
50+
git push

.github/workflows/draft.yaml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: release-draft
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
release-draft:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: Checkout code
11+
uses: actions/checkout@v4
12+
- name: Zip output
13+
run: |
14+
zip -r release.zip * -x .git/\* -x .github/\* -x release.zip -x Cargo\* -x src/\* -x md5buildignore.txt
15+
- name: Archive code coverage results
16+
uses: actions/upload-artifact@v3
17+
with:
18+
name: release-test
19+
path: release.zip
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: release-with-tag
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
8+
env:
9+
NAR_NAME: Ukaing
10+
11+
jobs:
12+
release-with-tag:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Checkout code
16+
uses: actions/checkout@v4
17+
- name: Zip output
18+
run: |
19+
zip -r release.zip * -x .git/\* -x .github/\* -x release.zip -x Cargo\* -x src/\* -x md5buildignore.txt
20+
- name: Create release
21+
id: create_release
22+
uses: actions/create-release@v1.0.0
23+
env:
24+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
25+
with:
26+
tag_name: ${{ github.ref }}
27+
release_name: Release ${{ github.ref }}
28+
draft: false
29+
prerelease: false
30+
- name: Upload Release Asset
31+
id: upload-release-asset
32+
uses: actions/upload-release-asset@v1.0.1
33+
env:
34+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
35+
with:
36+
upload_url: ${{ steps.create_release.outputs.upload_url }}
37+
asset_path: ./release.zip
38+
asset_name: ${{ env.NAR_NAME }}.nar
39+
asset_content_type: application/zip

.gitignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
profile/
2+
var.json
3+
/target/
4+
5+
*.log

0 commit comments

Comments
 (0)