update travis
This commit is contained in:
@@ -23,7 +23,7 @@ before_script:
|
|||||||
|
|
||||||
|
|
||||||
after_script:
|
after_script:
|
||||||
- sudo bash install --purge
|
- sudo -E bash install --purge
|
||||||
|
|
||||||
|
|
||||||
script:
|
script:
|
||||||
@@ -31,6 +31,7 @@ script:
|
|||||||
- sudo bash -c 'echo -e "[user]\n\tname = abc\n\temail = root@localhost.com" > /home/travis/.gitconfig'
|
- sudo bash -c 'echo -e "[user]\n\tname = abc\n\temail = root@localhost.com" > /home/travis/.gitconfig'
|
||||||
- sudo echo "Travis Banch = $TRAVIS_BRANCH"
|
- sudo echo "Travis Banch = $TRAVIS_BRANCH"
|
||||||
- sudo -E time bash install --travis -b "$TRAVIS_BRANCH"
|
- sudo -E time bash install --travis -b "$TRAVIS_BRANCH"
|
||||||
|
- sudo -E python3 -m pip install -U -r requirements.txt
|
||||||
- sudo -E time bash tests/travis.sh
|
- sudo -E time bash tests/travis.sh
|
||||||
- sudo wo update --travis
|
- sudo -E wo update --travis
|
||||||
- sudo python3 setup.py sdist bdist_wheel
|
- sudo python3 setup.py sdist bdist_wheel
|
||||||
@@ -999,10 +999,7 @@ class WOSiteUpdateController(CementBaseController):
|
|||||||
check_ssl = check_site.is_ssl
|
check_ssl = check_site.is_ssl
|
||||||
check_php_version = check_site.php_version
|
check_php_version = check_site.php_version
|
||||||
|
|
||||||
if check_php_version == "7.3":
|
old_php73 = bool(check_php_version == "7.3")
|
||||||
old_php73 = True
|
|
||||||
else:
|
|
||||||
old_php73 = False
|
|
||||||
|
|
||||||
if (pargs.password and not (pargs.html or
|
if (pargs.password and not (pargs.html or
|
||||||
pargs.php or pargs.php73 or pargs.mysql or
|
pargs.php or pargs.php73 or pargs.mysql or
|
||||||
@@ -1378,7 +1375,7 @@ class WOSiteUpdateController(CementBaseController):
|
|||||||
|
|
||||||
if 'proxy' in data.keys() and data['proxy']:
|
if 'proxy' in data.keys() and data['proxy']:
|
||||||
updateSiteInfo(self, wo_domain, stype=stype, cache=cache,
|
updateSiteInfo(self, wo_domain, stype=stype, cache=cache,
|
||||||
ssl=True if check_site.is_ssl else False)
|
ssl=(bool(check_site.is_ssl)))
|
||||||
Log.info(self, "Successfully updated site"
|
Log.info(self, "Successfully updated site"
|
||||||
" http://{0}".format(wo_domain))
|
" http://{0}".format(wo_domain))
|
||||||
return 0
|
return 0
|
||||||
|
|||||||
@@ -45,9 +45,6 @@ class WOUpdateController(CementBaseController):
|
|||||||
pargs = self.app.pargs
|
pargs = self.app.pargs
|
||||||
filename = "woupdate" + time.strftime("%Y%m%d-%H%M%S")
|
filename = "woupdate" + time.strftime("%Y%m%d-%H%M%S")
|
||||||
|
|
||||||
wo_current = WOVar.wo_version
|
|
||||||
wo_latest = WODownload.latest_release(self, "WordOps/WordOps")
|
|
||||||
|
|
||||||
install_args = ""
|
install_args = ""
|
||||||
if pargs.mainline or pargs.beta:
|
if pargs.mainline or pargs.beta:
|
||||||
wo_branch = "mainline"
|
wo_branch = "mainline"
|
||||||
@@ -64,6 +61,8 @@ class WOUpdateController(CementBaseController):
|
|||||||
if ((not pargs.force) and (not pargs.travis) and
|
if ((not pargs.force) and (not pargs.travis) and
|
||||||
(not pargs.mainline) and (not pargs.beta) and
|
(not pargs.mainline) and (not pargs.beta) and
|
||||||
(not pargs.branch)):
|
(not pargs.branch)):
|
||||||
|
wo_current = WOVar.wo_version
|
||||||
|
wo_latest = WODownload.latest_release(self, "WordOps/WordOps")
|
||||||
if wo_current == wo_latest:
|
if wo_current == wo_latest:
|
||||||
Log.error(
|
Log.error(
|
||||||
self, "WordOps {0} is already installed"
|
self, "WordOps {0} is already installed"
|
||||||
@@ -78,9 +77,7 @@ class WOUpdateController(CementBaseController):
|
|||||||
"update script"]])
|
"update script"]])
|
||||||
|
|
||||||
if os.path.isfile('install'):
|
if os.path.isfile('install'):
|
||||||
Log.info(self, "updating WordOps from local install\n"
|
Log.info(self, "updating WordOps from local install\n")
|
||||||
"Latest public release = {0}".format(wo_latest))
|
|
||||||
|
|
||||||
try:
|
try:
|
||||||
Log.info(self, "updating WordOps, please wait...")
|
Log.info(self, "updating WordOps, please wait...")
|
||||||
os.system("/bin/bash install --travis")
|
os.system("/bin/bash install --travis")
|
||||||
|
|||||||
@@ -44,9 +44,9 @@ class WODownload():
|
|||||||
'https://api.github.com/repos/{0}/releases/latest'
|
'https://api.github.com/repos/{0}/releases/latest'
|
||||||
.format(repository),
|
.format(repository),
|
||||||
timeout=(5, 30))
|
timeout=(5, 30))
|
||||||
|
github_json = req.json()
|
||||||
except requests.RequestException as e:
|
except requests.RequestException as e:
|
||||||
Log.debug(self, str(e))
|
Log.debug(self, str(e))
|
||||||
Log.error(self, "Unable to query GitHub API")
|
Log.error(self, "Unable to query GitHub API")
|
||||||
|
|
||||||
github_json = req.json()
|
|
||||||
return github_json["tag_name"]
|
return github_json["tag_name"]
|
||||||
|
|||||||
Reference in New Issue
Block a user