【问题标题】:ERROR watchman--no-pretty get-sockname when run npm start运行 npm start 时出现错误 watchman--no-pretty get-sockname
【发布时间】:2016-04-27 00:51:15
【问题描述】:

我知道这个错误已经解决了。我按照一切卸载然后重新安装。更新和升级。运行npm r -g watchman...但是尝试运行npm start时都失败了

我怀疑是因为我在 macbook 上的 LaunchAgents 已被中断。这是我运行时得到的

ls -ld ~/Library/LaunchAgents

lrwxr-xr-x  1 infacq  staff  46 Aug 16 11:03 /Users/infacq/Library/LaunchAgents -> /usr/local/opt/mysql/homebrew.mxcl.mysql.plist

有人经历过吗?

【问题讨论】:

    标签: macos npm homebrew react-native


    【解决方案1】:

    我认为你需要:

    rm /Users/infacq/Library/LaunchAgents
    

    您可能还需要:

    mkdir /Users/infacq/Library/LaunchAgents
    

    但您可能需要修复该目录的权限,以便其他人无法写入该目录

    【讨论】:

    • 我不熟悉设置权限。你能详细说明一下吗?如果我从 brew 安装任何其他东西,它会再次变得正常吗?
    【解决方案2】:

    同问题here

    尝试重新安装守望者:

    npm r -g watchman 
    brew update && brew upgrade
    brew install watchman
    

    我也不得不重新安装 libtool

    brew reinstall libtool --universal && brew unlink libtool && brew link libtool
    

    如果您在尝试执行以下操作时在 libtool 过程中遇到权限错误

    brew link pcre 
    
    Error: Could not symlink share/man/man3/pcre.3
    /usr/local/share/man/man3 is not writable.
    

    然后您需要按照here 所述更新您的权限

    sudo chown -R `whoami` /usr/local
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2020-07-02
      • 2021-01-01
      • 2021-12-18
      • 2020-02-04
      • 2021-09-07
      • 1970-01-01
      • 2022-11-19
      • 1970-01-01
      相关资源
      最近更新 更多