mirror of
https://github.com/robweber/xbmcbackup.git
synced 2024-11-15 04:45:49 +01:00
Version bump and README.txt
This commit is contained in:
parent
3a25c1c4eb
commit
35c1717699
31
README.txt
31
README.txt
@ -37,11 +37,38 @@ Once you have your app key and secret add them to the settings. XBMC Backup now
|
|||||||
|
|
||||||
Scripting XBMC Backup:
|
Scripting XBMC Backup:
|
||||||
|
|
||||||
If you wish to script this addon using an outside scheduler or script it can be given parameters via the Xbmc.RunScript() or JsonRPC.Addons.ExecuteAddon() methods. Parameters given are either "backup" or "restore" to launch the correct program mode. An example would be:
|
If you wish to script this addon using an outside scheduler or script it can be given parameters via the Xbmc.RunScript() or JsonRPC.Addons.ExecuteAddon() methods. Parameters given are either "backup" or "restore" to launch the correct program mode. If mode is "restore", an additional "archive" parameter can be given to set the restore point to be used instead of prompting via the GUI. An example would be:
|
||||||
|
|
||||||
RunScript(script.xbmcbackup,backup)
|
Python code:
|
||||||
|
-------------------------------------------
|
||||||
|
RunScript(script.xbmcbackup,mode=backup)
|
||||||
|
-------------------------------------------
|
||||||
|
|
||||||
|
or
|
||||||
|
|
||||||
|
JSON Request:
|
||||||
|
-------------------------------------------
|
||||||
|
{ "jsonrpc": "2.0", "method": "Addons.ExecuteAddon","params":{"addonid":"script.xbmcbackup","params":{"mode":"restore","archive":"000000000000"}}, "id": 1 }
|
||||||
|
-------------------------------------------
|
||||||
|
|
||||||
|
There is also a windows parameter that can be used to check if XBMC Backup is running within a skin or from another program. It is attached to the home window, an example of using it would be the following:
|
||||||
|
|
||||||
|
Python code:
|
||||||
|
-------------------------------------------
|
||||||
|
#kick off the xbmc backup
|
||||||
|
xbmc.executeJSONRPC('{ "jsonrpc": "2.0", "method": "Addons.ExecuteAddon","params":{"addonid":"script.xbmcbackup","params":{"mode":"backup"}}, "id": 1 }')
|
||||||
|
|
||||||
|
#sleep for a few seconds to give it time to kick off
|
||||||
|
xbmc.sleep(10000)
|
||||||
|
|
||||||
|
window = xbmcgui.Window(10000)
|
||||||
|
|
||||||
|
while (window.getProperty('script.xbmcbackup.running') == 'true'):
|
||||||
|
#do something here, probably just sleep for a few seconds
|
||||||
|
xbmc.sleep(5000)
|
||||||
|
|
||||||
|
#backup is now done, continue with script
|
||||||
|
-------------------------------------------
|
||||||
FAQ:
|
FAQ:
|
||||||
|
|
||||||
I can't see any restore points when choosing "Restore", what is the problem?
|
I can't see any restore points when choosing "Restore", what is the problem?
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||||
<addon id="script.xbmcbackup"
|
<addon id="script.xbmcbackup"
|
||||||
name="XBMC Backup" version="0.5.1" provider-name="robweber">
|
name="XBMC Backup" version="0.5.2" provider-name="robweber">
|
||||||
<requires>
|
<requires>
|
||||||
<import addon="xbmc.python" version="2.12.0"/>
|
<import addon="xbmc.python" version="2.12.0"/>
|
||||||
</requires>
|
</requires>
|
||||||
|
@ -1,3 +1,7 @@
|
|||||||
|
Version 0.5.2
|
||||||
|
|
||||||
|
added additional script and window parameters, thanks Samu-rai
|
||||||
|
|
||||||
Version 0.5.1
|
Version 0.5.1
|
||||||
|
|
||||||
updated for new Gotham xbmc python updates
|
updated for new Gotham xbmc python updates
|
||||||
|
Loading…
Reference in New Issue
Block a user