ci: add workflow for vericrypt publishing

This commit is contained in:
Abdullah Atta
2023-07-31 11:37:16 +05:00
committed by Abdullah Atta
parent 2b1812b5de
commit 022dd78eda
3 changed files with 34 additions and 0 deletions

31
.github/workflows/vericrypt.publish.yml vendored Normal file
View File

@@ -0,0 +1,31 @@
name: Publish @notesnook/vericrypt
on: workflow_dispatch
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node
uses: ./.github/actions/setup-node-with-cache
- name: Install packages
run: |
npm ci --ignore-scripts --prefer-offline --no-audit
npm run bootstrap -- --scope=vericrypt
- name: Setup environment
run: |
echo "NX_CLOUD_ACCESS_TOKEN=${{ secrets.NX_CLOUD_ACCESS_TOKEN }}" >> $GITHUB_ENV
echo "CLOUDFLARE_ACCOUNT_ID=${{ secrets.CLOUDFLARE_ACCOUNT_ID }}" >> $GITHUB_ENV
echo "CLOUDFLARE_API_TOKEN=${{ secrets.CLOUDFLARE_API_TOKEN }}" >> $GITHUB_ENV
- name: Generate desktop build
run: npm run build:vericrypt
- name: Publish on Cloudflare Pages
run: npx --yes wrangler pages publish --project-name=vericrypt ./apps/vericrypt/build/

View File

@@ -7,8 +7,10 @@
"clean": "node scripts/clean.mjs",
"build": "nx run-many --target=build --all --exclude=@notesnook/mobile,@notesnook/web",
"build:web": "nx build @notesnook/web",
"build:vericrypt": "nx build @notesnook/vericrypt",
"build:test:web": "nx build:test @notesnook/web",
"start:web": "nx start @notesnook/web",
"start:vericrypt": "nx start @notesnook/vericrypt",
"start:desktop": "nx start @notesnook/desktop",
"test:web": "nx test @notesnook/web",
"test:core": "nx test @notesnook/core",

View File

@@ -31,6 +31,7 @@ const IS_CI = process.env.CI;
const scopes = {
mobile: "apps/mobile",
web: "apps/web",
vericrypt: "apps/vericrypt",
desktop: "apps/desktop",
core: "packages/core",
editor: "packages/editor"