Skip to content

Commit

Permalink
changed to curl for update download and reverted back for now to bintray
Browse files Browse the repository at this point in the history
  • Loading branch information
DonDavici committed Feb 8, 2015
1 parent b851d99 commit 9f8e6fe
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions src/DP_SystemCheck.py
Original file line number Diff line number Diff line change
Expand Up @@ -243,25 +243,26 @@ def startUpdate(self, answer):
def updateToLatestVersion(self):
printl("", self, "S")

if config.plugins.dreamplex.updateType.value == "1":
updateType = "Stable"
else:
updateType = "Beta"
# if config.plugins.dreamplex.updateType.value == "1":
# updateType = "Stable"
# else:
# updateType = "Beta"

if getOeVersion() != "oe22":
#remoteUrl = "http://dl.bintray.com/dondavici/Dreambox/enigma2-plugin-extensions-dreamplex_" + str(self.latestVersion) + "_all.ipk?direct"
#remoteUrl = "http://bintray.com/artifact/download/dondavici/Dreambox/enigma2-plugin-extensions-dreamplex_" + str(self.latestVersion) + "_all.ipk"
remoteUrl = "http://sourceforge.net/projects/dreamplex/files/" + str(updateType) + "/ipk/enigma2-plugin-extensions-dreamplex_" + str(self.latestVersion) + "_all.ipk/download"
cmd = "opkg install --force-overwrite --force-depends " + str(remoteUrl)
#remoteUrl = "http://sourceforge.net/projects/dreamplex/files/" + str(updateType) + "/ipk/enigma2-plugin-extensions-dreamplex_" + str(self.latestVersion) + "_all.ipk/download"
#cmd = "opkg install --force-overwrite --force-depends " + str(remoteUrl)
cmd = "curl -o /tmp/temp.ipk -L -k https://bintray.com/artifact/download/dondavici/Dreambox/enigma2-plugin-extensions-dreamplex_" + str(self.latestVersion) + "_all.ipk && opkg install /tmp/temp.ipk; rm /tmp/temp.ipk"

else:
#remoteUrl = "http://dl.bintray.com/dondavici/Dreambox/enigma2-plugin-extensions-dreamplex_" + str(self.latestVersion) + "_all.deb?direct"
#remoteUrl = "http://bintray.com/artifact/download/dondavici/Dreambox/enigma2-plugin-extensions-dreamplex_" + str(self.latestVersion) + "_all.deb"
remoteUrl = "http://sourceforge.net/projects/dreamplex/files/" + str(updateType) + "/deb/enigma2-plugin-extensions-dreamplex_" + str(self.latestVersion) + "_all.deb/download"
#remoteUrl = "http://sourceforge.net/projects/dreamplex/files/" + str(updateType) + "/deb/enigma2-plugin-extensions-dreamplex_" + str(self.latestVersion) + "_all.deb/download"
#cmd = "dpkg --install " + str(remoteUrl) + " && apt-get update && apt-get -f install"
cmd = "URL='" + str(remoteUrl)+ "'; FILE=`mktemp`; wget $URL -qO $FILE && dpkg -i $FILE; rm $FILE"
#cmd = "URL='" + str(remoteUrl)+ "'; FILE=`mktemp`; wget $URL -qO $FILE && dpkg -i $FILE; rm $FILE"
cmd = "curl -o /tmp/temp.deb -L -k https://bintray.com/artifact/download/dondavici/Dreambox/enigma2-plugin-extensions-dreamplex_" + str(self.latestVersion) + "_all.dep && dpkg -i /tmp/temp.deb; rm /tmp/temp.deb"

printl("remoteUrl: " + str(remoteUrl), self, "D")
printl("cmd: " + str(cmd), self, "D")

self.session.open(SConsole,"Excecuting command:", [cmd] , self.finishupdate)
Expand Down

0 comments on commit 9f8e6fe

Please sign in to comment.