mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-16 10:03:51 -07:00
Update improvements
Include NzbDrone.Update in mono/osx package Do not ignore certificate warnings for services Check hash before extracting update New: Update support for Linux/OS X - see the wiki for more information
This commit is contained in:
parent
5c2f77339d
commit
ef3777fccf
46 changed files with 588 additions and 255 deletions
|
@ -12,19 +12,22 @@ define(
|
|||
template: 'Settings/General/GeneralViewTemplate',
|
||||
|
||||
events: {
|
||||
'change .x-auth' : '_setAuthOptionsVisibility',
|
||||
'change .x-ssl' : '_setSslOptionsVisibility',
|
||||
'click .x-reset-api-key' : '_resetApiKey'
|
||||
'change .x-auth' : '_setAuthOptionsVisibility',
|
||||
'change .x-ssl' : '_setSslOptionsVisibility',
|
||||
'click .x-reset-api-key' : '_resetApiKey',
|
||||
'change .x-update-mechanism' : '_setScriptGroupVisibility'
|
||||
},
|
||||
|
||||
ui: {
|
||||
authToggle : '.x-auth',
|
||||
authOptions : '.x-auth-options',
|
||||
sslToggle : '.x-ssl',
|
||||
sslOptions : '.x-ssl-options',
|
||||
resetApiKey : '.x-reset-api-key',
|
||||
copyApiKey : '.x-copy-api-key',
|
||||
apiKeyInput : '.x-api-key'
|
||||
authToggle : '.x-auth',
|
||||
authOptions : '.x-auth-options',
|
||||
sslToggle : '.x-ssl',
|
||||
sslOptions : '.x-ssl-options',
|
||||
resetApiKey : '.x-reset-api-key',
|
||||
copyApiKey : '.x-copy-api-key',
|
||||
apiKeyInput : '.x-api-key',
|
||||
updateMechanism : '.x-update-mechanism',
|
||||
scriptGroup : '.x-script-group'
|
||||
},
|
||||
|
||||
initialize: function () {
|
||||
|
@ -40,6 +43,10 @@ define(
|
|||
this.ui.sslOptions.hide();
|
||||
}
|
||||
|
||||
if (!this._showScriptGroup()) {
|
||||
this.ui.scriptGroup.hide();
|
||||
}
|
||||
|
||||
CommandController.bindToCommand({
|
||||
element: this.ui.resetApiKey,
|
||||
command: {
|
||||
|
@ -79,7 +86,7 @@ define(
|
|||
},
|
||||
|
||||
_resetApiKey: function () {
|
||||
if (window.confirm("Reset API Key?")) {
|
||||
if (window.confirm('Reset API Key?')) {
|
||||
CommandController.Execute('resetApiKey', {
|
||||
name : 'resetApiKey'
|
||||
});
|
||||
|
@ -90,6 +97,21 @@ define(
|
|||
if (options.command.get('name') === 'resetapikey') {
|
||||
this.model.fetch();
|
||||
}
|
||||
},
|
||||
|
||||
_setScriptGroupVisibility: function () {
|
||||
|
||||
if (this._showScriptGroup()) {
|
||||
this.ui.scriptGroup.slideDown();
|
||||
}
|
||||
|
||||
else {
|
||||
this.ui.scriptGroup.slideUp();
|
||||
}
|
||||
},
|
||||
|
||||
_showScriptGroup: function () {
|
||||
return this.ui.updateMechanism.val() === 'script';
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
@ -102,7 +102,7 @@
|
|||
<div class="col-sm-8">
|
||||
<div class="input-group">
|
||||
<label class="checkbox toggle well">
|
||||
<input type="checkbox" class='x-auth' name="authenticationEnabled"/>
|
||||
<input type="checkbox" class="x-auth" name="authenticationEnabled"/>
|
||||
<p>
|
||||
<span>On</span>
|
||||
<span>Off</span>
|
||||
|
@ -117,7 +117,7 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<div class='x-auth-options'>
|
||||
<div class="x-auth-options">
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">Username</label>
|
||||
|
||||
|
@ -174,9 +174,8 @@
|
|||
</div>
|
||||
</fieldset>
|
||||
|
||||
{{#if_windows}}
|
||||
<fieldset class="advanced-setting">
|
||||
<legend>Development</legend>
|
||||
<legend>Updating</legend>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">Branch</label>
|
||||
|
@ -186,28 +185,56 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<!--{{#if_mono}}-->
|
||||
<!--<div class="form-group">-->
|
||||
<!--<label class="control-label">Auto Update</label>-->
|
||||
{{#if_mono}}
|
||||
<div class="alert alert-warning">Please see: <a href="https://github.com/NzbDrone/NzbDrone/wiki/Updating">the wiki</a> for more information</div>
|
||||
|
||||
<!--<div class="controls">-->
|
||||
<!--<label class="checkbox toggle well">-->
|
||||
<!--<input type="checkbox" name="autoUpdate"/>-->
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">Automatic</label>
|
||||
|
||||
<!--<p>-->
|
||||
<!--<span>Yes</span>-->
|
||||
<!--<span>No</span>-->
|
||||
<!--</p>-->
|
||||
<div class="col-sm-8">
|
||||
<div class="input-group">
|
||||
<label class="checkbox toggle well">
|
||||
<input type="checkbox" name="updateAutomatically"/>
|
||||
<p>
|
||||
<span>On</span>
|
||||
<span>Off</span>
|
||||
</p>
|
||||
<div class="btn btn-primary slide-button"/>
|
||||
</label>
|
||||
|
||||
<!--<div class="btn btn-primary slide-button"/>-->
|
||||
<!--</label>-->
|
||||
<span class="help-inline-checkbox">
|
||||
<i class="icon-nd-form-info" title="Automatically download and install updates. You will still be able to install from System: Updates"/>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--<span class="help-inline-checkbox">-->
|
||||
<!--<i class="icon-nd-form-info" title="Use drone's built in auto update instead of package manager/manual updating"/>-->
|
||||
<!--</span>-->
|
||||
<!--</div>-->
|
||||
<!--</div>-->
|
||||
<!--{{/if_mono}}-->
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">Mechanism</label>
|
||||
|
||||
<div class="col-sm-1 col-sm-push-4 help-inline">
|
||||
<i class="icon-nd-form-info" title="Use built-in updater or external script"/>
|
||||
</div>
|
||||
|
||||
<div class="col-sm-4 col-sm-pull-1">
|
||||
<select name="updateMechanism" class="form-control x-update-mechanism">
|
||||
<option value="builtIn">Built-in</option>
|
||||
<option value="script">Script</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group x-script-group">
|
||||
<label class="col-sm-3 control-label">Script Path</label>
|
||||
|
||||
<div class="col-sm-1 col-sm-push-4 help-inline">
|
||||
<i class="icon-nd-form-info" title="Path to a custom script that take an extracted update package and handle the remainder of the update process"/>
|
||||
</div>
|
||||
|
||||
<div class="col-sm-4 col-sm-pull-1">
|
||||
<input type="text" name="updateScriptPath" class="form-control"/>
|
||||
</div>
|
||||
</div>
|
||||
{{/if_mono}}
|
||||
</fieldset>
|
||||
{{/if_windows}}
|
||||
</div>
|
||||
|
|
|
@ -5,17 +5,9 @@
|
|||
- {{ShortDate releaseDate}}
|
||||
{{#if installed}}<i class="icon-ok" title="Installed"></i>{{/if}}
|
||||
|
||||
{{#if_windows}}
|
||||
{{#if isUpgrade}}
|
||||
<span class="label label-default install-update x-install-update">Install</span>
|
||||
{{/if}}
|
||||
{{else}}
|
||||
{{#if isUpgrade}}
|
||||
<span class="label label-default install-update">
|
||||
<a href="https://github.com/NzbDrone/NzbDrone/wiki/Installation#linux">Install</a>
|
||||
</span>
|
||||
{{/if}}
|
||||
{{/if_windows}}
|
||||
{{#if isUpgrade}}
|
||||
<span class="label label-default install-update x-install-update">Install</span>
|
||||
{{/if}}
|
||||
</span>
|
||||
</legend>
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue