Skip to content

Commit

Permalink
Added auto update. v0.5.1
Browse files Browse the repository at this point in the history
  • Loading branch information
3wnbr1 committed Dec 16, 2020
1 parent 2f6f8f7 commit 5635754
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 2 deletions.
5 changes: 5 additions & 0 deletions main.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
const { app, BrowserWindow, ipcMain, dialog } = require('electron')
const { autoUpdater } = require("electron-updater");
const fs = require('fs')
const path = require('path')
var temp = require('temp')
Expand Down Expand Up @@ -77,6 +78,10 @@ function createWindow () {
// Some APIs can only be used after this event occurs.
app.whenReady().then(createWindow)

app.on('ready', function() {
autoUpdater.checkForUpdatesAndNotify();
});

app.on('open-file', (event, path) => {
file_path = path
})
Expand Down
10 changes: 8 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "Atlas",
"version": "0.5.0",
"version": "0.5.1",
"description": "Atas .rbsd files viewer",
"main": "main.js",
"scripts": {
Expand All @@ -21,6 +21,11 @@
"./textures/**",
"./preload.js"
],
"publish": [{
"provider": "github",
"owner": "robotique-ecam",
"repo": "Atlas"
}],
"fileAssociations": [
{
"ext": [
Expand Down Expand Up @@ -55,7 +60,7 @@
},
"repository": {
"type": "git",
"url": "git+https://github.com/3wnbr1/Atlas.git"
"url": "git+https://github.com/robotique-ecam/Atlas.git"
},
"author": "",
"license": "ISC",
Expand All @@ -65,6 +70,7 @@
"homepage": "https://github.com/3wnbr1/Atlas#readme",
"dependencies": {
"adm-zip": "^0.5.1",
"electron-updater": "^4.3.5",
"temp": "^0.9.1"
},
"devDependencies": {
Expand Down
23 changes: 23 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,11 @@
resolved "https://registry.yarnpkg.com/@types/node/-/node-12.19.9.tgz#990ad687ad8b26ef6dcc34a4f69c33d40c95b679"
integrity sha512-yj0DOaQeUrk3nJ0bd3Y5PeDRJ6W0r+kilosLA+dzF3dola/o9hxhMSg2sFvVcA2UHS5JSOsZp4S0c1OEXc4m1Q==

"@types/semver@^7.3.1":
version "7.3.4"
resolved "https://registry.yarnpkg.com/@types/semver/-/semver-7.3.4.tgz#43d7168fec6fa0988bb1a513a697b29296721afb"
integrity sha512-+nVsLKlcUCeMzD2ufHEYuJ9a2ovstb6Dp52A5VsoKxDXgvE051XgHI/33I1EymwkRGQkwnA0LkhnUzituGs4EQ==

"@types/yargs-parser@*":
version "15.0.0"
resolved "https://registry.yarnpkg.com/@types/yargs-parser/-/yargs-parser-15.0.0.tgz#cb3f9f741869e20cce330ffbeb9271590483882d"
Expand Down Expand Up @@ -531,6 +536,19 @@ [email protected]:
lazy-val "^1.0.4"
mime "^2.4.6"

electron-updater@^4.3.5:
version "4.3.5"
resolved "https://registry.yarnpkg.com/electron-updater/-/electron-updater-4.3.5.tgz#4fb36f593a031c87ea07ee141c9f064d5deffb15"
integrity sha512-5jjN7ebvfj1cLI0VZMdCnJk6aC4bP+dy7ryBf21vArR0JzpRVk0OZHA2QBD+H5rm6ZSeDYHOY6+8PrMEqJ4wlQ==
dependencies:
"@types/semver" "^7.3.1"
builder-util-runtime "8.7.2"
fs-extra "^9.0.1"
js-yaml "^3.14.0"
lazy-val "^1.0.4"
lodash.isequal "^4.5.0"
semver "^7.3.2"

electron@^11.1.0:
version "11.1.0"
resolved "https://registry.yarnpkg.com/electron/-/electron-11.1.0.tgz#8dfdf579d1eb79feef3e3d2937fc022e72129c90"
Expand Down Expand Up @@ -971,6 +989,11 @@ lazy-val@^1.0.4:
resolved "https://registry.yarnpkg.com/lazy-val/-/lazy-val-1.0.4.tgz#882636a7245c2cfe6e0a4e3ba6c5d68a137e5c65"
integrity sha512-u93kb2fPbIrfzBuLjZE+w+fJbUUMhNDXxNmMfaqNgpfQf1CO5ZSe2LfsnBqVAk7i/2NF48OSoRj+Xe2VT+lE8Q==

lodash.isequal@^4.5.0:
version "4.5.0"
resolved "https://registry.yarnpkg.com/lodash.isequal/-/lodash.isequal-4.5.0.tgz#415c4478f2bcc30120c22ce10ed3226f7d3e18e0"
integrity sha1-QVxEePK8wwEgwizhDtMib30+GOA=

lodash@^4.17.10:
version "4.17.20"
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.20.tgz#b44a9b6297bcb698f1c51a3545a2b3b368d59c52"
Expand Down

0 comments on commit 5635754

Please sign in to comment.