Skip to content

Commit

Permalink
fix(electron): show no update dialog
Browse files Browse the repository at this point in the history
  • Loading branch information
ocavue committed Jul 14, 2022
1 parent b6eff28 commit 733f3c3
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 3 deletions.
5 changes: 5 additions & 0 deletions .changeset/silver-eggs-smoke.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@rino.app/editor": patch
---

Fix an issue that causes update dialog not to display when checking update manually.
12 changes: 10 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -215,13 +215,21 @@ jobs:
- name: Create draft GitHub release
uses: softprops/action-gh-release@v1
if: ${{ github.ref == 'refs/heads/master' || github.ref == 'refs/heads/changeset-release/master' }}
if: ${{ github.ref == 'refs/heads/changeset-release/master' }}
with:
draft: true
prerelease: false
name: "${{ env.RINO_APP_VERSION }}"
tag_name: "${{ env.RINO_APP_VERSION }}"
append_body: false

- name: Create prerelease GitHub release
uses: softprops/action-gh-release@v1
if: ${{ github.ref == 'refs/heads/master' }}
with:
draft: false
prerelease: true
name: "${{ env.RINO_APP_VERSION }}"
tag_name: "${{ env.RINO_APP_VERSION }}"

release:
runs-on: ubuntu-latest
Expand Down
2 changes: 1 addition & 1 deletion packages/electron-main/src/updater.ts
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ export async function checkForUpdatesAutomatically(): Promise<void> {

export async function checkForUpdatesManually(): Promise<void> {
const foundNewVersion = await checkForUpdatesAndNotify(true)
if (foundNewVersion) {
if (!foundNewVersion) {
await showNoUpdateDialog()
}
}

0 comments on commit 733f3c3

Please sign in to comment.