Skip to content

Instantly share code, notes, and snippets.

@philgruneich
Forked from anonymous/FixMovieDiary.py
Created February 20, 2016 23:01
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save philgruneich/ad8e62c2b7b7ad1b7a7a to your computer and use it in GitHub Desktop.
Save philgruneich/ad8e62c2b7b7ad1b7a7a to your computer and use it in GitHub Desktop.
FixMovieDiary.py
# coding: utf-8
import keychain
import console
from urllib import quote, unquote
keychain.set_password('MovieDB', 'API', console.input_alert('Insert your MovieDB API key', '', keychain.get_password('MovieDB', 'API')))
keychain.set_password('Airtable', 'API', console.input_alert('Insert your Airtable API key', '', keychain.get_password('Airtable', 'API')))
keychain.set_password('Airtable', 'Movie Diary', console.input_alert('Insert your Airtable database ID', '', keychain.get_password('Airtable', 'Movie Diary')))
keychain.set_password('Airtable', 'Movie Diary Table', quote(console.input_alert('Insert the name of your Airtable table', '', unquote(keychain.get_password('Airtable', 'Movie Diary Table')))))
console.hud_alert('Updated configuration.')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment