Android Terminal does not recognise firebase command - firebase

I have this weird situation where I am not able to run firebase commands from android studio. I can run such commands in terminal but not in the terminal inside android studio.
As an example if I run firebase login in terminal, I can login but if run it in android studio I get this error: zsh: command not found: firebase.
See below an image to prove this case.
I tried to run the following command and got the following in terminal
MyMac:my_folder myuser$ which firebase
/Users/myuser/.nvm/versions/node/v17.0.1/bin/firebase
MyMac:my_folder myuser$ readlink $(which firebase)
../lib/node_modules/firebase-tools/lib/bin/firebase.js
If I do the same in Android I get nothing. I suspect it is a matter of Android studio not finding the right path to the firebase files?
Any help?
I am on a macOS Ventura and using Android Studio Electric Eel
Thanks so much!!

How did you install firebase tools (locally or globally)?
if you have globally installed firebase-cli,
I suggest you to look into environment PATH variables for both nodejs and firebase tools.
if you have installed locally as a dependancy,
here is a installation guide to install firebase-cli on macOS.
Eitherway, I suggest you to Invalidate cache and restart your Android studio before running the terminal again.

Related

Any solution for firebase packages integration in flutter in MacBook m1 pro

I have a flutter project which is dependent on some firebase services like auth, db etc. It was working fine on mac mini (intel). But on my MacBook pro I can't build project for podfile error. It showing firebase issue. Any solution?
There is no direct solution for the same. But there is a work around for resolving the Podfile related errors. Follow the steps below,
Execute the below command to install ffi from the terminal,
sudo arch -x86_64 gem install ffi
Then in the iOS folder of Flutter project execute the below command to install the pods. You have to run this command every time a new Flutter project is created and if it needs firebase.
arch -x86_64 pod install
Finally run the application in the Android studio

Flutter build failed stuck in 'pod install’ while trying to implement cloud firestore

After completing https://codelabs.developers.google.com/codelabs/flutter-firebase/#5 these code lab steps successfully. I tried to run the app. But it is stuck in the ‘pod install’ command. When I try to find the error opening the workspace in Xcode and attempted to run from there and I found a error message. It says the Cloud Firestore Plugin.h missing?
pls See the attached screenshot.
Remove Podfile.lock open command line tool and navigate to iOS folder of your flutter app.
Run pod install from command line tool. Verify all the pods are installed successfully.
Hope this helps!

heroku cli reports The system cannot find the path specified on Win 10

I'm having a problem with the Heroku CLI.
I was following the Heroku tutorial for Node.js.
I installed the Heroku CLI and checked that node --version, npm --version and git --version were at the latest version available.
I then run the command "heroku login" from git bash, but after inserting the email it complained about permissions so I re run git bash in administrator mode and everything seemed fine, I got to the part where you do "heroku create" it started downloading something but then I had a warning about not using git bash for "create" but to opt for powershell or cmd.
So I switched to cmd.exe with admin privileges but now the "heroku" command does nothing:
"$ heroku
The system cannot find the path specified."
The error seems related to my os, I checked my Windows Environment Variables and the path to heroku's exe is correctly set up (in fact it worked a bit earlier) to "C:\Program Files\Heroku\bin".
So I don't know how to use heroku at this point or what can I do to fix this error.

heroku cli commands not responding on windows 10

I installed heroku cli on windows 10 via exe installer.
When i try to run heroku --version command or heroku login
command, the command window does not respond. It does not give any error.
Then i uninstalled it and installed it using npm install -g heroku-cli
but getting same result.
Node version - 8.7.0
In Windows cmd prompt, do:
echo %USERPROFILE%
Go to your C:\Users\YOURNAME
Look for a file named:
_netrc
This file stores login credentials. Delete it.
Then check for an update:
heroku update
Then try to log in:
heroku login
I saw some people create an environment variable called HOME and add the path to YOURNAME so the environment knows to look for the _netrc file there.
Other trouble-shooting ideas if the above doesn't work for you can be found at Heroku CLI troubleshooting
In windows , run %LOCALAPPDATA%\heroku, completely delete this folder. and check again on cmd by typing heroku --version. Hope this helps.
I ended up uninstalling heroku from the Windows Installer and instead used the standalone tarball.
You can get the tarballs from here.
After you downloaded and extracted it, you can go to your terminal and cd into the directory where you extracted the file and do the following command:
./bin/heroku --version
Whenever you need the heroku CLI, you can cd into the directory where heroku is, then ./bin/heroku is the executable for heroku.

When attempting to install WhatsApp Messenger on Android-x86, I get the error: "Your device isn't compatible with this version."

Some applications install, while others don't. This one in particular, WhatsApp Messenger, is very important for me to get running, since my Mobile Android device needs repairs. How can I get this installed?
Have you tried to do it through Google Play?
Try direct link from whatsapp web-site.
I had the same error when I was trying to install the app from Google Play on my AVD. Perhaps following instruction will be helpful for you if you decide to run the app on the emulator.
There were my steps to install it (you already need an installed Android SDK or Bundle):
Download whatsapp (link is above)
Run your emulator
./LOCATION/TO/sdk/tools/emulator -avd VM_NAME_HERE -partition-size 500 -no-audio -no-boot-anim -netfast
Mount the storage:
./LOCATION/TO/sdk/tools/platform-tools/adb shell mount -o remount,rw -t yaffs2 /dev/block/mtdblock0 /system
Give permissions
./LOCATION/TO/sdk/tools/platform-tools/adb shell chmod 777 /system/app
Push the apk to the device:
./LOCATION/TO/sdk/tools/platform-tools/adb push /LOCATION/TO/YOUR/WHATAPP/APK/WhatsApp.apk /system/app/.
That's all

Resources