gpt4 book ai didi

android - Flutter doctor 终端命令不起作用

转载 作者:IT王子 更新时间:2023-10-29 07:07:22 28 4
gpt4 key购买 nike

$ Flutter doctor 终端命令无法在 ubuntu 上运行,给出错误消息“curl: (35) gnutls_handshake() failed: 拉函数错误。"

最佳答案

我使用的是 Ubuntu 18.04 LTS。假设您已成功下载并解压 flutter_linux_v0.5.1-beta.tar.xz (最新更新到现在)到您的首选目录。

export PATH=`pwd`/flutter/bin:$PATH

在您的 ubuntu 终端 (Ctrl + Alt + T) 中运行此命令会将 flutter 命令 PATH 变量添加到您的系统路径中以用于临时 session 。一旦关闭终端,系统路径就会被删除。

为了让 ubuntu 终端永久记住 flutter 命令,你需要:

1.) open up terminal and cd to $HOME. for eg: user@linux:~$

2.) open the hidden file .bashrc with your desired editor. It resides in $HOME.

3.) add the following line export PATH=/home/yourname/flutter/bin:$PATH somewhere as a newline in .bashrc file preferably as a last line edit & save file.

4.) run source /home/yourname/.bashrc in terminal to process your recent changes.

5.) finally, run echo $PATH to see flutter dir is in your system path along with other such paths. for eg: /home/yourname/flutter/bin

现在关闭当前终端并重新打开新终端以检查 flutter doctor。从现在开始,它应该每次都与所有其他可用的 flutter 命令一起处理。谢谢 ! :)

关于android - Flutter doctor 终端命令不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49319383/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com