Add proper main entry point to avoid execution when import.

This commit is contained in:
Florent
2014-02-27 11:33:30 +01:00
parent 558314f6f5
commit a91b74f9b4

View File

@@ -52,6 +52,7 @@ MDIMPORT = {
}
def main():
item = MDIMPORT[sys.argv[1]]
metad = None
@@ -66,3 +67,6 @@ if metad:
metad.load()
print metad.dumps()
if __name__ == '__main__':
main()