Skip to content

Commit

Permalink
upload file to drive through n8n
Browse files Browse the repository at this point in the history
  • Loading branch information
darwis059 committed Dec 31, 2022
1 parent e0366dd commit 610b277
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 15 deletions.
22 changes: 15 additions & 7 deletions .github/workflows/build-apk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -131,18 +131,26 @@ jobs:
- name: Rename Apk
run: |
mkdir builds
mv android/app-signed.apk ./builds/Logseq-android-${{ steps.ref.outputs.version }}.apk
mv android/app-signed.apk ./builds/logseq-android-${{ steps.ref.outputs.version }}.apk
- name: Upload Artifact
uses: actions/upload-artifact@v2
with:
name: logseq-android-builds
path: builds
# - name: Upload Artifact
# uses: actions/upload-artifact@v2
# with:
# name: logseq-android-builds
# path: builds

- name: Telegram Notify
uses: appleboy/telegram-action@master
with:
to: ${{ secrets.TELEGRAM_TO }}
token: ${{ secrets.TELEGRAM_TOKEN }}
message: Build Complete Logseq-android-${{ steps.ref.outputs.version }}.apk
document: builds/Logseq-android-${{ steps.ref.outputs.version }}.apk
document: builds/logseq-android-${{ steps.ref.outputs.version }}.apk

- name: Upload File
id: upload
uses: JantHsueh/upload-file-action@master
with:
url: https://n8n.darwis.id/webhook/8752e9b8-734a-4f7e-927a-052d592504ce
forms: '{"fileName":"logseq-android-${{ steps.ref.outputs.version }}.apk"}'
fileForms: '{"data":"builds/logseq-android-${{ steps.ref.outputs.version }}.apk"}'
24 changes: 16 additions & 8 deletions .github/workflows/build-js.yml
Original file line number Diff line number Diff line change
Expand Up @@ -119,25 +119,33 @@ jobs:
# working-directory: ./static/js

- name: Zip Js Files
run: zip logseq-js.zip ./js/* -r
run: zip logseq-js-${{ steps.ref.outputs.version }}.zip ./js/* -r
working-directory: ./static

- name: Upload Artifact
uses: actions/upload-artifact@v2
with:
name: logseq-js.zip
path: ./static/logseq-js.zip
# - name: Upload Artifact
# uses: actions/upload-artifact@v2
# with:
# name: logseq-js.zip
# path: ./static/logseq-js.zip

- name: Telegram Notify
uses: appleboy/telegram-action@master
with:
to: ${{ secrets.TELEGRAM_TO }}
token: ${{ secrets.TELEGRAM_TOKEN }}
message: Build Complete Logseq-js-${{ steps.ref.outputs.version }}
document: ./static/logseq-js.zip
document: ./static/logseq-js-${{ steps.ref.outputs.version }}.zip

- name: Upload File
id: upload
uses: JantHsueh/upload-file-action@master
with:
url: https://n8n.darwis.id/webhook/8752e9b8-734a-4f7e-927a-052d592504ce
forms: '{"fileName":"logseq-js-${{ steps.ref.outputs.version }}.zip"}'
fileForms: '{"data":"static/logseq-js-${{ steps.ref.outputs.version }}.zip"}'

- name: Remove Js Zip
run: rm logseq-js.zip
run: rm logseq-js-${{ steps.ref.outputs.version }}.zip
working-directory: ./static

- name: Move static to public
Expand Down

0 comments on commit 610b277

Please sign in to comment.