Problem: “Error: Could not find an installed version of Gradle either in Android Studio, or on your system to install the gradle wrapper. Please include gradle in your path, or install Android Studio”
My problem was also that the path wasn’t available system wide, I could say $gradle -v” in some terminals but not all, the solution below fixed this issue. This problem was happening when I was trying to build an Ionic App for android, I had Android Studio installed as well.