-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ea04dce
commit ffc20f9
Showing
5 changed files
with
30 additions
and
5 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,17 @@ | ||
const { app, BrowserWindow, globalShortcut } = require('electron'); | ||
const fs = require('fs'); | ||
var ua = require('universal-analytics'); | ||
const tracking_id = "UA-67885845-4"; | ||
var visitor = ua(tracking_id); | ||
const { init } = require('@sentry/electron'); | ||
init({ | ||
dsn: 'https://[email protected]/1446827', | ||
enableNative: false, | ||
}); | ||
|
||
// Keep a global reference of the window object, if you don't, the window will | ||
// be closed automatically when the JavaScript object is garbage collected. | ||
let win; | ||
const krlx_url = "http://live.krlx.org/data.php"; | ||
|
||
function createWindow () { | ||
|
||
|
@@ -13,7 +20,7 @@ function createWindow () { | |
|
||
// and load the index.html of the app. | ||
win.loadFile('index.html'); | ||
|
||
win.visitor = visitor; | ||
// Register media shortcuts | ||
globalShortcut.register("MediaPlayPause", | ||
function(){ | ||
|
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 |
---|---|---|
|
@@ -6,6 +6,15 @@ const Base64 = require('./node_modules/js-base64').Base64; | |
const fs = require('fs'); | ||
const moment = require('./assets/moment.min.js'); | ||
const spotify_api = require('./spotify_api.json'); | ||
const { init } = require('@sentry/electron'); | ||
let visitor = remote.getCurrentWindow().visitor; | ||
|
||
visitor.screenview("Home Screen", "KRLX Desktop", remote.app.getVersion()).send(); | ||
|
||
init({ | ||
dsn: 'https://[email protected]/1446827', | ||
enableNative: false, | ||
}); | ||
// The RegEx to resolve student images from the directory | ||
const DIR_REG = new RegExp('(<div class="email"><span class="icon">' + | ||
'\\n{0,1}<\\/span>(\\w+) )|<span class="icon"><\\/span><a href="mailto:(\\w+)@carleton.edu">'); | ||
|
@@ -321,7 +330,6 @@ function check_updates(){ | |
success: function(data){ | ||
console.log("Got update data"); | ||
console.log(data); | ||
console.log(shell); | ||
let curr_version = remote.app.getVersion(); | ||
let remote_version = data.updates.version; | ||
let update_url = data.updates.update; | ||
|
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