For the reference: if source file (.zip, .tgz, whatever) is not in the same directory as adb.exe or fastboot.exe, you can specify full path enclosed in " ".
For example
adb sideload "D:\MyFiles\Download\Xiaomi firmwares\fw_polaris.zip".
If you've followed our tutorial on how to setup the adb and fastboot platform tools on your computer, it might be annoying to have to navigate to the folder every time, especially if you use either tool quite frequently. Having to copy files to the platform tools folder is also annoying whenever you want to flash stuff on your device. For me it's frustrating as I use an SSD and I dislike having to copy my files to my platform tools folder, and then delete them after. However, it's possible to run the adb or fastboot tools from any directory on your Windows or Linux PC so you'll never have to change directories to run any commands.
PATH is used by Windows to specify the location of important executables. Usually, these are files located in the system directories, such as C:\Windows and C:\Windows\system32. This is why you can type "calc" in the command prompt to launch calculator, but not "chrome" to launch Google Chrome. This variable is sometimes changed by applications when you install them, such as Java. Java adds itself to the PATH variable on installation, meaning you can use Java from any directory. This is useful to people using Java applications so the program does not have to attempt to hard code the Java location.
We will be modifying the PATH system variable to allow us to use adb or Fastboot anywhere on our Windows computer. PATH also exists on Linux and usually contains the bin and sbin directories. I will cover how to add the platform tools to the Linux PATH variable too.
Note: Both tutorials require administrator/sudo access. Adding to Windows has two methods. I strongly suggest the first, but both work fine and the second is better if you plan to use the PATH variable a lot.
This isn't really adding it to the Windows PATH variable per se, but more adding it to a folder that is already in the PATH variable. Simply copy your adb.exe, fastboot.exe, AdbWinApi.dll and AdbWinUsbApi.dll to C:\Windows and you're good to go. You should be able to run adb and fastboot from the command line now. This is by far the easiest, most fool proof method for setting this up. If for whatever reason it doesn't work, follow method 2.
Click "Browse" and navigate to the folder where you extracted your adb files. Next "okay" out of all of the Windows you have open. Start a new PowerShell or command prompt and type "adb" to verify the location has been added. If not, reboot your PC and try again.
Please ensure before you click "Browse" that no field is highlighted. If a field is highlighted you will end up replacing it. Click somewhere in the list that doesn't contain an entry to ensure that you do not replace a field.
I will be using Ubuntu for this tutorial, via command line only. You can edit the .bashrc file via the GUI, but you will need to navigate to the root of your home directory and press Ctrl+H. Make sure you have the platform-tools downloaded and extracted.
You are now done, you should now be able to simply execute the adb or fastboot commands from anywhere on your Windows or Linux computer. As I said, this is incredibly useful and also allows for better organization so that you don't need to put all of your flashable files in the same folders.
Installs the executable and DLL files to enable ADB and FASTBOOT functionality from any command line in the operating system. Configures automatically system's parameters and it's even compatible with the Windows PowerShell. It's always based on the latest Android SDK available.
Download Android ADB Fastboot 1.7 from our software library for free. Our antivirus scan shows that this download is clean. The following versions: 1.7, 1.3 and 1.2 are the most frequently downloaded ones by the program users.
Android ADB Fastboot was developed to work on Windows XP, Windows XP Professional, Windows Vista, Windows 7, Windows 8, Windows 10 or Windows 11 and is compatible with 32-bit systems. Adb.exe and fastboot.exe are the most frequent filenames for this program's installer. This free program was originally designed by Ruben Alamina. The file size of the latest downloadable installer is 3.7 MB. The software is included in System Utilities.
Android ADB Fastboot is a simple tool designed to manage the files on your android device. After installing Android ADB Fastboot you can open a command prompt and type adb or fastboot commands. After that, you can proceed to configure your Android device by typing the right commands for your desired operations. This installer is 32-bit and 64-bit compatible.
The platform-tools folder is significant because it houses a pair of files (adb.exe and fastboot.exe) that the Windows command prompt needs to reference before it can send any ADB or Fastboot commands. But if you're sending any files or mods over to your Android device, the Windows command prompt also needs those to be in the same folder, unless you're willing to type out the full file location.
So until now, the easiest way to install mods with ADB or Fastboot was to move necessary files into the platform-tools folder, then open a command window in the same folder. That way, the mod files, plus the adb.exe and fastboot.exe files, would be in the same place, giving the Windows command prompt everything it needs.
Thankfully, there's now a way to bake ADB and Fastboot into the Windows command prompt itself, which lets you immediately run ADB upon opening the command prompt. With this enabled, you won't have to worry about file locations. Instead, just open up a command window in the same folder your mod files are located, and you'll be able to run ADB and Fastboot with a set of simple commands.
Before we get started, you'll need to download Google's new standalone platform-tools package in order to mesh it into the Windows command prompt. This standalone version doesn't come bundled with the full Android Studio, so it's easier to install. Feel free to head to our full guide for more information on the standalone platform-tools package, but otherwise, you can grab the ZIP from the following link:
Once you have the platform-tools ZIP downloaded, you'll need to extract it to a folder that's easy to locate. As such, we'd recommend creating a folder named Android in the root of the C:\ drive (C:\Android\), then extracting the files there. This will make it easy to remember and locate, as we'll need to revisit it later on.
Select the Advanced tab on the new window, then click "Environment Variables" on the bottom-right side and another window will appear. Go to the new window and locate System Variables section on the lower half of the popup, then double click the "Path" entry.
After your computer fully boots up, hold down the shift button on your keyboard, then right-click any empty space in any folder (even on your desktop) and select "Open command window here" to open up a command terminal. From here, enter "adb start-server" into the prompt (without the quotes), and if everything went off without a hitch, you'll see a message saying "daemon started successfully."
Alternatively, you can also test for this new feature by pressing the Windows key and typing "cmd" into the search bar. Type "fastboot" in the command line once it opens up, and you'll be greeted with a slew of available Fastboot commands.
From now on, whenever you need to flash an IMG file with Fastboot or push and pull files with ADB, you'll simply need to open the command window in the same folder as the target files using the shift/right-click trick. In other words, with this mod set up, you are now free to mod your Android phone to your heart's content!
c01484d022