【发布时间】:2021-08-18 04:36:39
【问题描述】:
我在尝试让我的 TS 应用在 Bitbucket 管道中编译时遇到问题。
这是我的 .yaml 文件:
image: node:10.16.3
pipelines:
pull-requests:
'**':
- step:
name: Install dependencies
caches:
- node
script:
- npm install -g typescript
- npm install
- parallel:
- step:
name: Build App
caches:
- node
size: 2x
script:
- node -v && npm -v && tsc -v
- npm run build
- step:
name: Run Tests
caches:
- node
script:
- echo "Run tests"
但是它失败并出现以下错误:
bash: tsc: 找不到命令
我花了很长时间在谷歌上搜索试图找到答案,但我没有运气解决这个问题。几个月前我尝试过,但失败了,今天我回过头来试一试,但仍然没有成功。
我们将不胜感激任何帮助。感谢您的支持
【问题讨论】:
-
如果删除
- node -v && npm -v && tsc -v行,您的构建脚本是否仍然无法找到tsc?它是否会出现相同的错误消息? -
@kdau 因内存不足而失败
FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory
标签: typescript yaml bitbucket-pipelines