我们正在尝试在CircleCI上建立我们的项目,目前在纱线安装部分使项目失败。
我们收到的错误是
$ sed -i'''s /#import
/#import“ RCTValueAnimatedNode.h” /'./node_modules/react-native/Libraries/NativeAnimation/RCTNativeAnimatedNodesManager.h
sed:无法读取s /#import
/#import“ RCTValueAnimatedNode.h” /:没有此类文件或目录
在package.json中,我们有一个后安装脚本可以更正此问题
"sed -i '' 's/#import <RCTAnimation\\/RCTValueAnimatedNode.h>/#import \"RCTValueAnimatedNode.h\"/' ./node_modules/react-native/Libraries/NativeAnimation/RCTNativeAnimatedNodesManager.h"
问题是我们很难找到方法或将其放置在config.yml中,或者这是否是解决问题的正确途径。
我们的config.yml看起来像
jobs:
build:
working_directory: ~/project
environment:
LC_ALL: C.UTF-8
LANG: C.UTF-8
docker:
- image: circleci/node:latest
## setup
steps:
- checkout
- restore_cache:
key: yarn-v1-{{ checksum "yarn.lock" }}-{{ arch }}
- restore_cache:
key: node-v1-{{ checksum "package.json" }}-{{ arch }}
- run: yarn install
- save_cache:
key: yarn-v1-{{ checksum "yarn.lock" }}-{{ arch }}
paths:
- ~/.cache/yarn
- save_cache:
key: node-v1-{{ checksum "package.json" }}-{{ arch }}
paths:
- node_modules
## run tests
- run:
name: jest tests
command: yarn test
建议和煽动将不胜感激