Skip to content

Commit

Permalink
preserve-symlinks
Browse files Browse the repository at this point in the history
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
  • Loading branch information
Tyler Smalley committed Feb 17, 2021
1 parent be78169 commit 9595fc9
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 6 deletions.
10 changes: 7 additions & 3 deletions src/dev/typescript/build_ts_refs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,12 @@ export async function buildAllTsRefs(log: ToolingLog) {
for (const path of REF_CONFIG_PATHS) {
const relative = Path.relative(REPO_ROOT, path);
log.debug(`Building TypeScript projects refs for ${relative}...`);
await execa(require.resolve('typescript/bin/tsc'), ['-b', relative, '--pretty'], {
cwd: REPO_ROOT,
});
await execa(
'node',
['--preserve-symlinks', require.resolve('typescript/bin/tsc'), '-b', relative, '--pretty'],
{
cwd: REPO_ROOT,
}
);
}
}
2 changes: 1 addition & 1 deletion test/scripts/checks/build_ts_refs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
source src/dev/ci_setup/setup_env.sh

checks-reporter-with-killswitch "Build Typescript Refs" \
node scripts/build_ts_refs
node --preserve-symlinks scripts/build_ts_refs
3 changes: 1 addition & 2 deletions test/scripts/checks/type_check.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,4 @@
source src/dev/ci_setup/setup_env.sh

checks-reporter-with-killswitch "Check Types" \
node scripts/build_ts_refs && \
node scripts/type_check
node --preserve-symlinks scripts/type_check
1 change: 1 addition & 0 deletions test/scripts/jenkins_unit.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ if [[ -z "$CODE_COVERAGE" ]] ; then
./test/scripts/checks/ts_projects.sh
./test/scripts/checks/jest_configs.sh
./test/scripts/checks/doc_api_changes.sh
./test/scripts/checks/build_ts_refs.sh
./test/scripts/checks/type_check.sh
./test/scripts/checks/bundle_limits.sh
./test/scripts/checks/i18n.sh
Expand Down
1 change: 1 addition & 0 deletions vars/tasks.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ def check() {
kibanaPipeline.scriptTask('Check TypeScript Projects', 'test/scripts/checks/ts_projects.sh'),
kibanaPipeline.scriptTask('Check Jest Configs', 'test/scripts/checks/jest_configs.sh'),
kibanaPipeline.scriptTask('Check Doc API Changes', 'test/scripts/checks/doc_api_changes.sh'),
kibanaPipeline.scriptTask('Build Typescript Refs', 'test/scripts/checks/build_ts_refs.sh'),
kibanaPipeline.scriptTask('Check Types', 'test/scripts/checks/type_check.sh'),
kibanaPipeline.scriptTask('Check Bundle Limits', 'test/scripts/checks/bundle_limits.sh'),
kibanaPipeline.scriptTask('Check i18n', 'test/scripts/checks/i18n.sh'),
Expand Down

0 comments on commit 9595fc9

Please sign in to comment.