mirror of
https://github.com/gristlabs/grist-core.git
synced 2026-03-02 04:09:24 +00:00
add a script for copying schema information from python to typescript
There was no script for updating typescript schema information after a python-based document migration. Moving one in here, along with its test. Tweaked the code slightly to work with grist-core's directory structure. Also fixed a formatting error in mocha calls that was resulting in some root tests not running.
This commit is contained in:
@@ -32,7 +32,10 @@ import { GristObjCode } from "app/plugin/GristData";
|
||||
export const SCHEMA_VERSION = %d;
|
||||
|
||||
export const schema = {
|
||||
""" % (__file__, schema.SCHEMA_VERSION))
|
||||
""" % ('core/sandbox/gen_js_schema.py', schema.SCHEMA_VERSION))
|
||||
# The script name is hardcoded since the Grist sandbox can be
|
||||
# at different paths depending on how Grist is installed, and
|
||||
# we don't want unnecessary changes to generated files.
|
||||
|
||||
for table in schema.schema_create_actions():
|
||||
print(' "%s": {' % table.table_id)
|
||||
|
||||
Reference in New Issue
Block a user