Skip to content

Commit

Permalink
Create nightly.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
andelf authored Mar 20, 2024
1 parent d76e8eb commit 84acfe6
Showing 1 changed file with 48 additions and 0 deletions.
48 changes: 48 additions & 0 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: metapac publish

on:
push:
branches: [ "main" ]

env:
CARGO_TERM_COLOR: always

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Use nightly Rust
run: rustup default nightly
- name: Deploy SSH key
run: |
mkdir ~/.ssh
echo "${{ secrets.NIGHTLIES_KEY }}" > ~/.ssh/id_rsa
chmod 700 ~/.ssh
chmod 600 ~/.ssh/id_rsa
ssh-keyscan -t rsa github.com
- name: Build
run: |
COMMIT=$(git rev-parse HEAD)
COMMIT_MESSAGE=$(git log -1 --pretty=%B)
./d gen
cd build/ch32-metapac/
cp -v ../../README.md .
cp -v ../../LICENSE* .
git init
git add .
git config user.name "ch32-data builder"
git config user.email "[email protected]"
git commit -m "ch32-rs/ch32-data master $COMMIT"
git branch -M main
git remote add origin [email protected]:ch32-rs/ch32-metapac.git
- name: Test
run: |
cd build/ch32-metapac/
cargo doc --features ch32v307vct6,metadata
- name: Push
run: |
cd build/ch32-metapac/
git push --force origin main

0 comments on commit 84acfe6

Please sign in to comment.