libcloud-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From to...@apache.org
Subject [libcloud] branch trunk updated: Update script which triggers RTD build to use new RTD webhook api.
Date Thu, 30 May 2019 18:48:10 GMT
This is an automated email from the ASF dual-hosted git repository.

tomaz pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/libcloud.git


The following commit(s) were added to refs/heads/trunk by this push:
     new b891626  Update script which triggers RTD build to use new RTD webhook api.
b891626 is described below

commit b891626c751705de70ea5a3869fcaa5fae974868
Author: Tomaz Muraus <tomaz@tomaz.me>
AuthorDate: Thu May 30 20:47:01 2019 +0200

    Update script which triggers RTD build to use new RTD webhook api.
---
 .travis.yml                  | 4 +++-
 contrib/trigger_rtd_build.py | 9 +++++----
 2 files changed, 8 insertions(+), 5 deletions(-)

diff --git a/.travis.yml b/.travis.yml
index 11ad275..65fda5c 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -34,7 +34,9 @@ matrix:
     - env: ENV=coverage
       python: 2.7
       before_script: TOX_ENV=coverage-travis
-    - env: ENV=docs
+    - env:
+        - ENV=docs
+        - secure: "d4F2RE2iWFh6yqE5MUxnakDihBMsY/hMsaMWllVAYU/fvCMKhaW97d51EiS55kur/eNVX2jpEqkVkSu5VeNSxC3w9sZTG+dHVb8A43o9QaSCPngvHTZ4X9fx8lB96G7uju6pmm5ovKt85hxZW2uQNYo3ugwCUl94lVDYqo+KJUM="
       python: 3.5
       before_script: TOX_ENV=docs-travis
       # Note: graphviz is needed for grapgs embedded in the docs
diff --git a/contrib/trigger_rtd_build.py b/contrib/trigger_rtd_build.py
index 0ab6166..f9d5972 100755
--- a/contrib/trigger_rtd_build.py
+++ b/contrib/trigger_rtd_build.py
@@ -14,11 +14,12 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-import sys
+import os
+
 import requests
 
+token = os.environ['RTD_TOKEN']
 
-key = sys.argv[1]
-url = 'https://readthedocs.org/build/%s' % (key)
-r = requests.post(url)
+url = 'https://readthedocs.org/api/v2/webhook/libcloud/87656/'
+r = requests.post(url, data={'token': token})
 print(r.text)


Mime
View raw message