Skip to content

Commit

Permalink
Add env variable for debugging
Browse files Browse the repository at this point in the history
  • Loading branch information
protocol7 committed Jul 28, 2019
1 parent 0775341 commit d28392e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions javaenv
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ import tarfile
import tempfile
import urllib

DEBUG = os.environ.get("JAVAENV_DEBUG") == "true"
javaenv_home = os.path.expanduser(
"~/.javaenv/") # TODO override with env variable
versions_dir = javaenv_home + "versions/"

# TODO move to json?
VERSIONS = {
"openjdk-9.0.4": {
"url":
Expand All @@ -39,7 +39,8 @@ VERSIONS = {


def debug(msg):
print(msg, file=sys.stderr)
if DEBUG:
print(msg, file=sys.stderr)


def make_versions_dir():
Expand Down

0 comments on commit d28392e

Please sign in to comment.