⨯ EPERM: operation not permitted, link ...

新增区块链相关包后,项目在部署的时候报错,报错内容如下:

报错信息:

⨯ EPERM: operation not permitted, link 
'/Users/XXX/.cache/act/be662ca67b3f7553/hostexecutor/node_modules/bigint-buffer/build/node_gyp_bins/python3'
 -> 
'/Users/XXX/.cache/act/be662ca67b3f7553/hostexecutor/release/win-unpacked/resources/app.asar.unpacked/node_modules/bigint-
buffer/build/node_gyp_bins/python3' failedTask=build stackTrace=Error: ...

报错截图: 

 

修复:

构建版本中增加

USE_HARD_LINKS: false

部署文件内容如下,注意空格 

name: 持续构建
on: [pull_request]

jobs:
  持续构建:
    runs-on: macOS

    steps:
      - name: 检出代码
        uses: actions/checkout@v3
        
      - name: 计算哈希
        uses: seepine/hash-files@v1
        id: get-hash
        with: 
          patterns: |-
            package.json
            package-lock.json            

      - name: 保存缓存
        id: cache
        uses: actions/cache@v3
        with:
          path: node_modules
          key: ChainTradeClient-${{ steps.get-hash.outputs.hash }}

      - name: 安装依赖
        if: steps.cache.outputs.cache-hit != 'true'
        run: npm i --registry=http://registry.npmmirror.com

      - name: 单元测试
        run: npm run test

      - name: 构建版本
        env:
          # no hardlinks so dependencies are copied
          USE_HARD_LINKS: false
        run: npm run build-win

参考:

https://github.com/TypeStrong/ts-node/issues/422

  • 2
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值