2016-09-18 08:33:46 +00:00
|
|
|
# Use with
|
|
|
|
# py -i etiquette_easy.py
|
|
|
|
|
|
|
|
import phototagger
|
2016-10-30 01:46:23 +00:00
|
|
|
import os
|
|
|
|
import sys
|
2016-09-18 08:33:46 +00:00
|
|
|
P = phototagger.PhotoDB()
|
|
|
|
import traceback
|
|
|
|
|
|
|
|
def easytagger():
|
|
|
|
while True:
|
|
|
|
i = input('> ')
|
|
|
|
if i.startswith('?'):
|
|
|
|
i = i.split('?')[1] or None
|
|
|
|
try:
|
|
|
|
P.export_tags(specific_tag=i)
|
|
|
|
except:
|
|
|
|
traceback.print_exc()
|
2016-10-18 05:13:12 +00:00
|
|
|
else:
|
|
|
|
P.easybake(i)
|
2016-09-18 08:33:46 +00:00
|
|
|
|
|
|
|
def photag(photoid):
|
|
|
|
photo = P.get_photo_by_id(photoid)
|
|
|
|
print(photo.tags())
|
|
|
|
while True:
|
|
|
|
photo.add_tag(input('> '))
|
|
|
|
get=P.get_tag
|