Skip to content

Commit 49ddf2a

Browse files
committed
Add command to save a default-schema.json file.
You use `make update_default_schema` from the top-level repo file.
1 parent ab595f6 commit 49ddf2a

File tree

3 files changed

+14629
-0
lines changed

3 files changed

+14629
-0
lines changed

make_instructions.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ Available targets (i.e. $ make target):
1818

1919
readme -> `less` this file
2020

21+
update_default_schema -> download the latest plot schema from plot.ly
22+
2123
setup_subs -> delete old submodule locations, init, update, and sync new
2224

2325
install -> 1. sync submodules 2. install plotly with setup.py

makefile

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,15 @@ setup_subs :
1717
git submodule update
1818
make sync_subs
1919

20+
update_default_schema :
21+
@echo "Making sure the default-schema.json file is up to date"
22+
python -c "import json;\
23+
from plotly.graph_reference import GRAPH_REFERENCE;\
24+
f = open('plotly/graph_reference/default-schema.json', 'w');\
25+
json.dump(GRAPH_REFERENCE, f, indent=4, sort_keys=True,\
26+
separators=(',', ': '));\
27+
f.close()"
28+
2029
install : sync_subs
2130
@echo ""
2231
@echo "Installing Python API with make"

0 commit comments

Comments
 (0)