Maxython / termux-sdk

5 stars 0 forks source link

Issue while installing platform-tools #1

Closed BlackberrieCake137 closed 6 months ago

BlackberrieCake137 commented 6 months ago

Hi! I'm a bit of a newb to termux and using the shell in general, trying to install platform-tools to wirelessly debug a device. I ran into this issue in trying to install platform-tools


Traceback (most recent call last):
  File "/data/data/com.termux/files/usr/bin/sdkmanager", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/data/data/com.termux/files/usr/lib/python3.11/site-packages/sdkmanager.py", line 1208, in main
    method(args.packages)
  File "/data/data/com.termux/files/usr/lib/python3.11/site-packages/sdkmanager.py", line 1008, in install
    android_home = get_android_home()
                   ^^^^^^^^^^^^^^^^^^
  File "/data/data/com.termux/files/usr/lib/python3.11/site-packages/sdkmanager.py", line 551, in get_android_home
    raise FileNotFoundError('ANDROID_HOME "%s" does not exist!' % android_home)
FileNotFoundError: ANDROID_HOME "/opt/android-sdk" does not exist!```
Maxython commented 6 months ago

It looks like you are trying to install it via sdkmanager. You need to install it via the termux-sdk command, because the command has a configured environment (shell) for sdkmanager.

termux-sdk "platform-tools"