I followed document to add firebase in my flutter app. I got 1 warning and message like
Warning: Pub installs executables into $HOME/.pub-cache/bin, which is not on your path.
You can fix that by adding this to your shell's config file (.bashrc, .bash_profile, etc.):
Warning: Pub installs executables into $HOME/.pub-cache/bin, which is not on your path.
You can fix that by adding this to your shell's config file (.bashrc, .bash_profile, etc.):
export PATH="$PATH":"$HOME/.pub-cache/bin"
Activated flutterfire_cli 0.1.1+2.
after this i used
flutterfire configure
and i got this error (not an error) zsh: command not found: flutterfire
How to resolve this? and I this any environment error?
set path to flutterfire by running command vim ~/.bash_profile press i for insert paste the path export PATH="$PATH":"$HOME/.pub-cache/bin" press esc key to save then :wq to exit
you can run which flutterfire to check path
Set path for zsh on Mac:
vim ~/.zshrc
i
export PATH="$PATH":"$HOME/.pub-cache/bin"
esc
:wq!
and press enterIf successfull which flutterfire
will work.
[I am using Mac] This helped me, Just keep in mind when you follow below steps from officialwebsite :-
npm install -g firebase-tools
firebase login
dart pub global activate flutterfire_cli
flutterfire configure
If flutterfire configure
doesnot work then, Add:
export PATH="$PATH":"$HOME/.pub-cache/bin"
to your .bash_profile
from Home directory of your mac. Now, Restart your system, And after opening your system, try flutterfire configure
again in VS Code. It will work. Then:
flutter pub add firebase_core
flutter pub get
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.