Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Functions | Variables
tools.reformat-json Namespace Reference

Functions

 Reformat (filename)
 
 _Main ()
 

Variables

 GM_DIRECTORY
 

Function Documentation

◆ _Main()

tools.reformat-json._Main ( )
protected

Definition at line 49 of file reformat-json.py.

49def _Main():
50 parser = argparse.ArgumentParser(description='Reformat JSON files in-place.')
51 parser.add_argument('filenames', metavar='FILENAME', nargs='+',
52 help='file to reformat')
53 args = parser.parse_args()
54 for filename in args.filenames:
55 Reformat(filename)
56 sys.exit(0)
57

◆ Reformat()

tools.reformat-json.Reformat (   filename)

Definition at line 45 of file reformat-json.py.

45def Reformat(filename):
46 print('Reformatting file %s...' % filename)
47 gm_json.WriteToFile(gm_json.LoadFromFile(filename), filename)
48
void print(void *str)
Definition bridge.cpp:126

Variable Documentation

◆ GM_DIRECTORY

tools.reformat-json.GM_DIRECTORY
Initial value:
1= os.path.realpath(
2 os.path.join(os.path.dirname(os.path.dirname(__file__)), 'gm'))

Definition at line 39 of file reformat-json.py.