[bts-link] 01/01: store the github token in a safe location
Sandro Tosi
morph at moszumanska.debian.org
Mon Dec 7 00:36:44 UTC 2015
This is an automated email from the git hooks/post-receive script.
morph pushed a commit to branch master
in repository bts-link.
commit ec562221fcdcf5dacf7e85b410fe1874aa436f2c
Author: Sandro Tosi <morph at debian.org>
Date: Mon Dec 7 00:36:40 2015 +0000
store the github token in a safe location
---
remote/github.py | 5 ++---
remote/secrets.py | 37 +++++++++++++++++++++++++++++++++++++
2 files changed, 39 insertions(+), 3 deletions(-)
diff --git a/remote/github.py b/remote/github.py
index 5d87d7e..ca13d56 100644
--- a/remote/github.py
+++ b/remote/github.py
@@ -33,10 +33,9 @@ import urllib2, urlparse, cgi, re, json
from BeautifulSoup import BeautifulSoup
from __init__ import *
+from secrets import SECRETS
-# https://developer.github.com/v3/oauth/
-# Currently is a personal token under my GH username
-TOKEN = 'c2c4a9422480affa63d4f17ffba47867cc9c00c8'
+TOKEN = SECRETS['github']
class GithubData:
def __init__(self, uri, id):
diff --git a/remote/secrets.py b/remote/secrets.py
new file mode 100644
index 0000000..1163690
--- /dev/null
+++ b/remote/secrets.py
@@ -0,0 +1,37 @@
+# vim:set encoding=utf-8:
+###############################################################################
+# Copyright:
+# � 2015 Sandro Tosi <morph at debian.org>
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. The names of its contributors may not be used to endorse or promote
+# products derived from this software without specific prior written
+# permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+# EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+###############################################################################
+
+# Module to store login/auth information
+# run "git update-index --skip-worktree remote/secrets.py"
+# and change it locally with real values
+
+SECRETS = {
+ # https://developer.github.com/v3/oauth/
+ 'github': 'dummy-token',
+}
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/bts-link/bts-link.git
More information about the bts-link-commits
mailing list