From 611106843680ac5c1e18d6ccdaf104338ed3266c Mon Sep 17 00:00:00 2001 From: Alyssa Rosenzweig Date: Mon, 25 Jun 2018 14:17:22 -0400 Subject: [PATCH] Load config --- config.json | 4 ++-- libremanage.py | 5 +++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/config.json b/config.json index 5eec4ea..fcdccb2 100644 --- a/config.json +++ b/config.json @@ -6,9 +6,9 @@ }, "managers": { "myboard": { - "host": "rosenzweig.io", + "host": "192.168.7.2", "port": 22, - "username": "alyssa" + "username": "root" } } } diff --git a/libremanage.py b/libremanage.py index 7700739..88a7d6b 100644 --- a/libremanage.py +++ b/libremanage.py @@ -18,6 +18,7 @@ along with this program. If not, see . """ import sys +import json import functools USAGE = """ @@ -37,6 +38,10 @@ Valid commands are as follows: - tty: Open TTY in GNU Screen """ +with open("config.json") as f: + CONFIG = json.load(f) +print(CONFIG) + def die_with_usage(message): print(message) print(USAGE) -- 2.25.1