Permalink
Browse files

Merge branch '1.1.X'

  • Loading branch information...
brosner committed Jul 5, 2012
2 parents 74b8a7c + b4a0104 commit e9c02a06c5052be7db9b1956fe0796728826e791
Showing with 18 additions and 13 deletions.
  1. +8 −2 CHANGELOG.rst
  2. +1 −1 gondor/__init__.py
  3. +8 −6 gondor/__main__.py
  4. +1 −4 gondor/api.py
View
@@ -2,8 +2,14 @@
CHANGELOG
=========
-1.1 (dev)
-=========
+1.1.1
+=====
+
+ * fixed auth.password bugs (password is no longer used in 1.1+.)
+ * added check for site key existence
+
+1.1
+===
* added --upgrade to init to perform a configuration upgrade
* changed configuration format from INI to YAML (~/.gondor can remain in INI format)
View
@@ -1 +1 @@
-__version__ = "1.1"
+__version__ = "1.1.1"
View
@@ -989,12 +989,14 @@ def main():
except OSError:
error("unable to find a %s directory.\n" % vcs_dir)
- if (config["auth.username"] is None and (config["auth.password"] is None or config["auth.key"] is None)):
- message = "you must set your credentials in %s" % os.path.expanduser("~/.gondor")
- if "project_root" in env:
- message += " or %s" % os.path.join(env["project_root"], config_file)
- message += "\n"
- error(message)
+ if config["auth.username"] is None or config["auth.key"] is None:
+ error(
+ "you must provide a username and API key in %s or set it in "
+ "the environment.\n" % os.path.expanduser("~/.gondor")
+ )
+
+ if config["gondor.site_key"] is None:
+ error("no site key found in configuration or environment.\n")
{
"init": cmd_init,
View
@@ -14,9 +14,6 @@ def make_api_call(config, url, params=None, extra_handlers=None):
request = urllib2.Request(url, params)
request.add_unredirected_header(
"Authorization",
- "Basic %s" % base64.b64encode("%s:%s" % (
- config["auth.username"],
- config["auth.key"] or config["auth.password"]
- )).strip()
+ "Basic %s" % base64.b64encode("%s:%s" % (config["auth.username"], config["auth.key"])).strip()
)
return opener.open(request)

0 comments on commit e9c02a0

Please sign in to comment.