Skip to content

Commit fbe40b2

Browse files
committed
chore: updated github actions
1 parent 2ea7255 commit fbe40b2

File tree

3 files changed

+65
-3
lines changed

3 files changed

+65
-3
lines changed
Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: Build
22

3-
on: [push, pull_request]
3+
on: [push, pull_request, workflow_call]
44

55
permissions:
66
contents: write
@@ -22,10 +22,16 @@ jobs:
2222
run: bun install
2323

2424
- name: Build 🚧
25-
run: bun build:bun
25+
run: bun build:all
2626

27-
- name: Upload Artifact 🚀
27+
- name: Upload Package artifact 🚀
2828
uses: actions/upload-artifact@v4
2929
with:
3030
name: ya-ocr
3131
path: dist/*
32+
33+
- name: Upload Docs artifact 🚀
34+
id: deployment
35+
uses: actions/upload-pages-artifact@v3
36+
with:
37+
path: docs

.github/workflows/docs.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Docs
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
permissions:
9+
contents: write
10+
pages: write # to deploy to Pages
11+
id-token: write # to verify the deployment originates from an appropriate source
12+
13+
jobs:
14+
build:
15+
name: Build
16+
uses: ./.github/workflows/build.yml
17+
18+
deploy:
19+
needs: build
20+
21+
# Deploy to the github-pages environment
22+
environment:
23+
name: github-pages
24+
url: ${{ steps.deployment.outputs.page_url }}
25+
runs-on: ubuntu-latest
26+
steps:
27+
- name: Deploy to GitHub Pages
28+
id: deployment
29+
uses: actions/deploy-pages@v4

.github/workflows/release.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
permissions:
9+
contents: write
10+
11+
jobs:
12+
build_release:
13+
name: Build Release
14+
uses: ./.github/workflows/build.yml
15+
16+
create_release:
17+
needs: build_release
18+
runs-on: ubuntu-latest
19+
steps:
20+
- name: Create release
21+
uses: softprops/action-gh-release@v2
22+
with:
23+
token: ${{ secrets.GITHUB_TOKEN }}
24+
tag_name: ${{ github.ref }}
25+
name: ${{ github.sha }}
26+
draft: true
27+
prerelease: false

0 commit comments

Comments
 (0)