From 057fda53520b1d63b8e6679eb5ebb22a355a2be4 Mon Sep 17 00:00:00 2001 From: Zeke Sikelianos Date: Wed, 18 Jan 2017 11:00:13 -0800 Subject: [PATCH 1/2] set version arg when creating electron-api.json --- script/create-dist.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/script/create-dist.py b/script/create-dist.py index 368617f0f1de..fa66e34fbd50 100755 --- a/script/create-dist.py +++ b/script/create-dist.py @@ -133,7 +133,8 @@ def copy_license(): def create_api_json_schema(): outfile = os.path.join(DIST_DIR, 'electron-api.json') - execute(['electron-docs-linter', '--outfile={0}'.format(outfile)]) + execute(['electron-docs-linter', '--outfile={0}'.format(outfile)], + '--version={}'.format(ELECTRON_VERSION.replace('v', ''))) def strip_binaries(): for binary in TARGET_BINARIES[PLATFORM]: From 6af7cfff33b682f4b4435c592f4394075c9f7e09 Mon Sep 17 00:00:00 2001 From: Zeke Sikelianos Date: Wed, 18 Jan 2017 11:52:09 -0800 Subject: [PATCH 2/2] fix syntax and use relative path to electron-api.json target --- script/create-dist.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/script/create-dist.py b/script/create-dist.py index fa66e34fbd50..f777d7a6ee50 100755 --- a/script/create-dist.py +++ b/script/create-dist.py @@ -132,9 +132,9 @@ def copy_license(): shutil.copy2(os.path.join(SOURCE_ROOT, 'LICENSE'), DIST_DIR) def create_api_json_schema(): - outfile = os.path.join(DIST_DIR, 'electron-api.json') - execute(['electron-docs-linter', '--outfile={0}'.format(outfile)], - '--version={}'.format(ELECTRON_VERSION.replace('v', ''))) + outfile = os.path.relpath(os.path.join(DIST_DIR, 'electron-api.json')) + execute(['electron-docs-linter', 'docs', '--outfile={0}'.format(outfile), + '--version={}'.format(ELECTRON_VERSION.replace('v', ''))]) def strip_binaries(): for binary in TARGET_BINARIES[PLATFORM]: