File tree Expand file tree Collapse file tree 2 files changed +12
-4
lines changed
Expand file tree Collapse file tree 2 files changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -24,11 +24,11 @@ Add new games
2424
25253. **Update the catalog: **
2626
27- Use the ``update_catalog.py `` script to update the Gambit's documentation & build files.
27+ Use the ``update_catalog.py `` script to update Gambit's documentation & build files.
2828
2929 .. code-block :: bash
3030
31- python src/pygambit/update_catalog.py
31+ python src/pygambit/update_catalog.py --build
3232
3333 .. note ::
3434
Original file line number Diff line number Diff line change 1+ import argparse
12from pathlib import Path
23
34import pygambit as gbt
@@ -46,13 +47,20 @@ def update_makefile():
4647
4748 if content != updated_content :
4849 print (f"Updated { str (MAKEFILE_AM )} " )
50+ else :
51+ print (f"No changes to add to { str (MAKEFILE_AM )} " )
4952
5053
5154if __name__ == "__main__" :
5255
56+ parser = argparse .ArgumentParser ()
57+ parser .add_argument ("--build" , action = "store_true" )
58+ args = parser .parse_args ()
59+
5360 # Create CSV used by RST docs page
5461 gbt .catalog .games ().to_csv (CATALOG_CSV , index = False )
55- print (f"Generated { CATALOG_CSV } for use in docs build." )
62+ print (f"Generated { CATALOG_CSV } for use in local docs build. DO NOT COMMIT ." )
5663
5764 # Update the Makefile.am with the current list of catalog files
58- update_makefile ()
65+ if args .build :
66+ update_makefile ()
You can’t perform that action at this time.
0 commit comments