From 0d86b144f5ad064e09302d4501da9e4756efb881 Mon Sep 17 00:00:00 2001 From: j Date: Wed, 14 Mar 2018 16:55:41 +0530 Subject: [PATCH 1/2] format readme --- README.md | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 393245f..51ab006 100644 --- a/README.md +++ b/README.md @@ -26,14 +26,13 @@ This will create playlist.mp4 - install brew (https://brew.sh/) - install dependencies - brew instlal python3 - brew instlal git - brew install libvpx libvorbis libopus - brew install ffmpeg --with-libvpx --with-libvorbis --with-libopus - - pip3 install ox + brew instlal python3 + brew instlal git + brew install libvpx libvorbis libopus + brew install ffmpeg --with-libvpx --with-libvorbis --with-libopus + pip3 install ox - install pandora_render - git clone https://code.0x2620.org/0x2620/pandora_render.git - + git clone https://code.0x2620.org/0x2620/pandora_render.git + From 23cd8ac541aed7441987bd9b4e4dd16394d6eb61 Mon Sep 17 00:00:00 2001 From: j Date: Wed, 14 Mar 2018 16:56:49 +0530 Subject: [PATCH 2/2] only store password if login worked --- edit.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/edit.py b/edit.py index fd2d127..b11a7f7 100755 --- a/edit.py +++ b/edit.py @@ -142,6 +142,7 @@ if __name__ == '__main__': 'password': data['password'] } + update = False if not credentials: try: credentials = ox.web.auth.get(site) @@ -150,7 +151,7 @@ if __name__ == '__main__': print('Please provide your username and password for %s:' % site) credentials['username'] = input('Username: ') credentials['password'] = getpass.getpass('Password: ') - ox.web.auth.update(site, credentials) + update = True api = API(base_url + '/api/') r = api.signin(**credentials) @@ -158,6 +159,8 @@ if __name__ == '__main__': for kv in r['data']['errors'].items(): print('%s: %s' % kv) sys.exit(1) + if update: + ox.web.auth.update(site, credentials) print('Edit:', edit_id) print('Sort:', sort_by) r = api.getEdit(id=edit_id)