{"action":"created","issue":{"url":"https://api.github.com/repos/JdeH/Transcrypt/issues/132","repository_url":"https://api.github.com/repos/JdeH/Transcrypt","labels_url":"https://api.github.com/repos/JdeH/Transcrypt/issues/132/labels{/name}","comments_url":"https://api.github.com/repos/JdeH/Transcrypt/issues/132/comments","events_url":"https://api.github.com/repos/JdeH/Transcrypt/issues/132/events","html_url":"https://github.com/JdeH/Transcrypt/issues/132","id":182467665,"number":132,"title":"Have a config file with 'personal' preferences.","user":{"login":"JdeH","id":1730289,"avatar_url":"https://avatars.githubusercontent.com/u/1730289?v=3","gravatar_id":"","url":"https://api.github.com/users/JdeH","html_url":"https://github.com/JdeH","followers_url":"https://api.github.com/users/JdeH/followers","following_url":"https://api.github.com/users/JdeH/following{/other_user}","gists_url":"https://api.github.com/users/JdeH/gists{/gist_id}","starred_url":"https://api.github.com/users/JdeH/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JdeH/subscriptions","organizations_url":"https://api.github.com/users/JdeH/orgs","repos_url":"https://api.github.com/users/JdeH/repos","events_url":"https://api.github.com/users/JdeH/events{/privacy}","received_events_url":"https://api.github.com/users/JdeH/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/JdeH/Transcrypt/labels/enhancement","name":"enhancement","color":"0000ff"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":14,"created_at":"2016-10-12T08:42:23Z","updated_at":"2016-10-12T12:07:50Z","closed_at":null,"body":"There are quite some command line switches now, and not everything is easily said in command line format.\r\n\r\nSo a config file will be added, most likely in the JSON format, since it's univeral, easy to parse and not as bloated and overly formalized as XML.\r\n"},"comment":{"url":"https://api.github.com/repos/JdeH/Transcrypt/issues/comments/253195819","html_url":"https://github.com/JdeH/Transcrypt/issues/132#issuecomment-253195819","issue_url":"https://api.github.com/repos/JdeH/Transcrypt/issues/132","id":253195819,"user":{"login":"JdeH","id":1730289,"avatar_url":"https://avatars.githubusercontent.com/u/1730289?v=3","gravatar_id":"","url":"https://api.github.com/users/JdeH","html_url":"https://github.com/JdeH","followers_url":"https://api.github.com/users/JdeH/followers","following_url":"https://api.github.com/users/JdeH/following{/other_user}","gists_url":"https://api.github.com/users/JdeH/gists{/gist_id}","starred_url":"https://api.github.com/users/JdeH/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JdeH/subscriptions","organizations_url":"https://api.github.com/users/JdeH/orgs","repos_url":"https://api.github.com/users/JdeH/repos","events_url":"https://api.github.com/users/JdeH/events{/privacy}","received_events_url":"https://api.github.com/users/JdeH/received_events","type":"User","site_admin":false},"created_at":"2016-10-12T12:07:50Z","updated_at":"2016-10-12T12:07:50Z","body":"The meta-info you're looking for is already there:\r\n\r\n```\r\nclass CommandArgs:\r\n\tdef parse (self):\r\n\t\tself.argParser = ArgumentParser ()\r\n\t\t\r\n\t\tself.argParser.add_argument ('source', nargs='?', help = \".py file containing source code of main module\")\r\n\t\tself.argParser.add_argument ('-a', '--anno', help = \"annotate target files that were compiled from Python with source file names and source line numbers\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-b', '--build', help = \"rebuild all target files from scratch\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-c', '--complex', help = \"enable complex number support, locally requires operator overloading\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-dc', '--dcheck', help = \"debug: perform lightweight consistency check\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-da', '--dassert', help = \"debug: activate assertions\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-de', '--dextex', help = \"debug: show extended exception reports\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-dm', '--dmap', help = \"debug: dump human readable source map\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-dt', '--dtree', help = \"debug: dump syntax tree\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-ds', '--dstat', help = \"debug: validate static typing using annotations\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-e', '--esv', nargs='?', help = \"ecma script version of generated code, default = 5. The symbol __esv<versionnr>__ is added to the global symbol list, e.g. __esv6__.\")\r\n\t\tself.argParser.add_argument ('-f', '--fcall', help = \"enable fastcall mechanism by default. You can also use __pragma__ ('fcal') and __pragma__ (\\'nofcall\\')\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-g', '--gen', help = \"enable generators and iterators. Disadvised, since it will result in a function call for each loop iteration. Preferably use __pragma__ ('gen') and __pragma__ ('nogen')\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-i', '--iconv', help = \"enable automatic conversion to iterable by default. Disadvised, since it will result in a type check for each for-loop. Preferably use __pragma__ ('iconv') and __pragma__ (\\'noiconv\\') to enable automatic conversion locally\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-j', '--jskeys', help = \"interpret {key: 'value'} as {'key': 'value'} and forbid {key (): 'value'}, as JavaScript does. Disadvised, since it's less flexible than the Python interpretation. Either follow Python semantics by using {'key': 'value'} explicitly if you want literal keys or use __pragma__ ('jskeys') and __pragma__ ('nojskeys') locally instead to make clear local deviation from Python semantics\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-k', '--kwargs', help = \"enable keyword arguments by default. In general this is disadvised, use __pragma__ ('kwargs') and __pragma__('nokwargs') locally instead to prevent bloated code\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-l', '--license', help = \"show license\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-m', '--map', help = \"generate source map\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-n', '--nomin', help = \"no minification\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-o', '--opov', help = \"enable operator overloading by default. In general this is disadvised, use __pragma__ ('opov') and __pragma__('noopov') locally instead to prevent slow code\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-p', '--parent', nargs='?', help = \"object that will hold module, default is window. Use -p .none to generate orphan module, e.g. for use in node.js. Use -p .user to generate module that has to be explicitly initialized by calling <modulename> (), e.g. after the full page has loaded\")\r\n\t\tself.argParser.add_argument ('-r', '--run', help = \"run source file rather than compiling it\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-s', '--symbols', nargs='?', help = \"names, joined by $, separately passed to main module in __symbols__ variable\")\r\n\t\tself.argParser.add_argument ('-t', '--tconv', help = \"enable automatic conversion to truth value by default. Disadvised, since it will result in a conversion for each boolean. Preferably use __pragma__ ('tconv') and __pragma__ (\\'notconv\\') to enable automatic conversion locally\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-v', '--verbose', help = \"show all messages\", action = 'store_true')\r\n\t\tself.argParser.add_argument ('-*', '--star', help = \"Like it? Grow it! Go to GitHub and then click [* Star]\", action = 'store_true')\r\n\t\t\r\n\t\tself.__dict__.update (self.argParser.parse_args () .__dict__)\r\n```\r\nThe last line above copies all relevant configuration attributes to the dict of this. In the same way you can get hold of them for the config parser.\r\n\r\n\r\n"}}
{"actor":{"display_login":"JdeH"}}