reverted __main__ to master, so that we can use it to generate docs in the console