ruby-on-rails - 错误运行 rails -server,接收错误:纱线:错误:没有这样的选项:--integrity
问题描述
我在 Rails 6.0.3.4 和 Ruby 2.7.1 中工作,当我运行时rails -s
,我在终端中收到以下错误:
Usage: yarn [options]
yarn: error: no such option: --integrity
========================================
Your Yarn packages are out of date!
Please run `yarn install --check-files` to update.
========================================
To disable this check, please change `check_yarn_integrity`
to `false` in your webpacker config file (config/webpacker.yml).
当我运行时yarn install --check-files
,我收到以下错误:
yarn: error: no such option: --check-files
我确实在 webpacker.yml 中将 check_yarn_integrity 设置为 false。
解决方案
尝试使用npm install --global yarn
推荐阅读
- c++ - 在编译系统中,linker(ld) 如何知道将 myprogram.o 链接到谁?
- android - 如何在自定义 ArrayList 中保存 FCM 通知?
- r - 如何在 R 中使用更改的数据名称进行循环
- codenameone - 在代号中写入具有给定笔划宽度和字体大小的字符串
- php - 使用php将文本变量从文本文件传递到html表单单元格
- python-3.x - 转换和连接来自 csv 文件的两列的数据
- python - 如何解决这个 python portaudio 绑定问题?
- c# - 无法使用 OrderBy C# 功能以某种方式对列表进行排序
- ios - 如何防止意外触摸触发 swift 4.2 中的 touchesBegan?
- python - Django 在静态文件中使用值