-
Notifications
You must be signed in to change notification settings - Fork 414
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Auto Update with electron-updater (WIP) #808
Merged
Merged
Changes from all commits
Commits
Show all changes
36 commits
Select commit
Hold shift + click to select a range
285c1ca
Add electron-updater requirement and import
alexliebowitz 2031f36
Upgrade to electron-builder 19.45.5
alexliebowitz 43297ce
Add electron-log
alexliebowitz dade117
Add updater settings to package.json
alexliebowitz b202de4
Upload assets for latest version to S3 in a separate directory
alexliebowitz bd8146a
Add electron-publisher-s3 requirement
alexliebowitz 67c3863
Don't try to upload latest-linux.yml file on Linux
alexliebowitz e39470c
Copy dmg file into dist/mac for TeamCity
alexliebowitz 5fff24b
Add "auto update downloaded" modal
alexliebowitz 24ced8e
More core UI for auto-update
alexliebowitz 565f411
Make app actually quit for update
alexliebowitz 3957bf2
Finish core UI for auto update
alexliebowitz acec4a7
Remove S3 upload from upload_assets.py
alexliebowitz bc15d24
Add ability to decline updates
alexliebowitz b08d96d
Add alert before close after update is declined on Windows
alexliebowitz b03623e
Convert Windows update alert dialog to native dialog in main process
alexliebowitz 3959d4a
Make app restart after user approves update
alexliebowitz cf3406f
Remove icon from the Windows auto-update alert dialog shown on closing
alexliebowitz fb8aee4
Version 0.31 [temp, for testing]
alexliebowitz 5a475f4
Version 0.32 [temp, for testing]
alexliebowitz 0c8ba50
Update Auto Update-related copy
alexliebowitz f244f90
Add back "Upgrade App" button on Mac/Win with different dialog on click
alexliebowitz dccb06c
Version 0.35 [temp, for testing]
alexliebowitz 863f7dc
Make new dialogs behave correctly when video is playing
alexliebowitz 853bf2c
Make video pause when you hit the "Upgrade Now" button on Mac/Win
alexliebowitz 2d33767
Change version to 0.1.0 [temp, for testing]
alexliebowitz 37b5ec9
Change version to 0.2.0 [temp, for testing]
alexliebowitz 483809b
Merge remote-tracking branch 'origin/master' into auto-update
alexliebowitz 3e84907
Version 0.3.0 [temp, for testing]
alexliebowitz fbc143a
Reword "Upgrade on Restart" to "Upgrade on Close"
alexliebowitz daca49d
Add release notes to auto update dialogs
alexliebowitz 8c0bf32
Small changes to prepare auto update for release
alexliebowitz f302a0f
Merge branch 'master' into auto-update
alexliebowitz eef3f6a
Restore version number with -dev suffix (needed for new build process)
alexliebowitz 76f6b1e
Remove remaining traces of logging code from main/index.js
alexliebowitz e98231f
Don't show auto-update dialog after decline on Win/Mac
alexliebowitz File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import React from "react"; | ||
import { connect } from "react-redux"; | ||
import { doCloseModal, doAutoUpdateDeclined } from "redux/actions/app"; | ||
import ModalAutoUpdateConfirm from "./view"; | ||
|
||
const perform = dispatch => ({ | ||
closeModal: () => dispatch(doCloseModal()), | ||
declineAutoUpdate: () => dispatch(doAutoUpdateDeclined()), | ||
}); | ||
|
||
export default connect(null, perform)(ModalAutoUpdateConfirm); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
import React from "react"; | ||
import { Modal } from "modal/modal"; | ||
import { Line } from "rc-progress"; | ||
import Link from "component/link/index"; | ||
|
||
const { ipcRenderer } = require("electron"); | ||
|
||
class ModalAutoUpdateConfirm extends React.PureComponent { | ||
render() { | ||
const { closeModal, declineAutoUpdate } = this.props; | ||
|
||
return ( | ||
<Modal | ||
isOpen={true} | ||
type="confirm" | ||
contentLabel={__("Update Downloaded")} | ||
confirmButtonLabel={__("Upgrade")} | ||
abortButtonLabel={__("Not now")} | ||
onConfirmed={() => { | ||
ipcRenderer.send("autoUpdateAccepted"); | ||
}} | ||
onAborted={() => { | ||
declineAutoUpdate(); | ||
closeModal(); | ||
}} | ||
> | ||
<section> | ||
<h3 className="text-center">{__("LBRY Update Ready")}</h3> | ||
<p> | ||
{__( | ||
'Your LBRY update is ready. Restart LBRY now to use it!' | ||
)} | ||
</p> | ||
<p className="meta text-center"> | ||
{__('Want to know what has changed?')} See the{' '} | ||
<Link label={__('release notes')} href="https://github.com/lbryio/lbry-app/releases" />. | ||
</p> | ||
</section> | ||
</Modal> | ||
); | ||
} | ||
} | ||
|
||
export default ModalAutoUpdateConfirm; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import React from "react"; | ||
import { connect } from "react-redux"; | ||
import { doCloseModal, doAutoUpdateDeclined } from "redux/actions/app"; | ||
import ModalAutoUpdateDownloaded from "./view"; | ||
|
||
const perform = dispatch => ({ | ||
closeModal: () => dispatch(doCloseModal()), | ||
declineAutoUpdate: () => dispatch(doAutoUpdateDeclined()), | ||
}); | ||
|
||
export default connect(null, perform)(ModalAutoUpdateDownloaded); |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't be better to change TeamCity config directly?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would, but I figured we would worry about it later. It's already going to be a little complicated to roll out auto update.