AOSP Command Reference
Your comprehensive, interactive reference for Android Open Source Project commands. Search, filter, and explore essential AOSP development commands with examples and safety information.
Why Use Our Command Reference?
Smart Search
Quickly find commands with intelligent search and filtering across categories
One-Click Copy
Copy commands to clipboard with a single click for immediate use
Category Filtering
Browse commands by category: Build System, ADB, Git, Debugging, and more
Downloadable Cheat Sheets
Export command references as PDF cheat sheets for offline use
Safety Indicators
Visual warnings for destructive commands to prevent accidental data loss
Detailed Examples
Each command includes usage examples and parameter explanations
Key Features
Real-time Search
Find commands instantly as you type with fuzzy search
Safety Warnings
Clear indicators for potentially destructive commands
Usage Examples
Practical examples with parameter explanations
Category Organization
Commands organized by Build System, ADB, Git, and more
Export Options
Download filtered results as PDF cheat sheets
Mobile Friendly
Responsive design works perfectly on all devices
Interactive Command Reference
Start typing to search commands, use filters to narrow results, and click any command to copy it to your clipboard.
Command Reference
Comprehensive database of AOSP development commands with examples and safety information
Found 131 commands
adb devicesList all connected Android devices
adb kill-serverStop the ADB server process
adb start-serverStart the ADB server process
adb rebootReboot the device
adb shell dfDisplay disk usage on the device
adb pushCopy files from computer to device
adb pullCopy files from device to computer
adb shell getpropGet Android system properties
adb shell cat /proc/cpuinfoDisplay CPU information of the device
adb installInstall APK package on device
adb uninstallUninstall an app from the device
adb shell pm list packagesList installed packages on the device
adb shell pm pathShow the path of an app's APK
adb shell pm dumpDump detailed information about a package
adb logcatView device system logs
adb shell "logcat >/sdcard/log000.log"Save device logs to a file on the device
adb shell wm helpDisplay help for window manager commands
adb shell wm sizeGet or set the device screen size
adb shell wm densityGet or set the device screen density
adb shell psList running processes on the device
adb rootRestart ADB with root privileges
adb disable-verityDisable Android Verified Boot
adb remountRemount system partitions as writable
adb shell screencapCapture a screenshot of the device screen
adb shell screenrecordRecord the device screen
adb shell dumpsys activityDump activity manager state
adb shell setpropSet Android system properties
adb shell dumpsys package queriesDump package query information
adb shell dumpsys procstatsDump process statistics
adb shell dumpsys gfxinfoDump graphics performance information
adb shell am startStart an activity on the device
adb shell am force-stopForce stop an app
adb shell pm clearClear app data
adb shell am startserviceStart a service on the device
adb shell am start-foreground-serviceStart a foreground service on the device
adb shell am broadcastSend a broadcast intent
adb shell pingTest network connectivity from the device
adb shell netstatDisplay network connections and statistics
adb shell tcpdumpCapture network packets on the device
adb shell geteventCapture device input events
adb shell inputSimulate input events on the device
adb shell settingsManage device settings
adb shellOpen interactive shell on device
fastboot devicesList devices in fastboot mode
fastboot flashFlash partition with image file
fastboot eraseErase partition
fastboot rebootReboot the device from fastboot mode
fastboot oem unlockUnlock the device bootloader
fastboot oem lockLock the device bootloader
fastboot flashing unlockUnlock bootloader for flashing (newer devices)
fastboot flashing lockLock bootloader to prevent flashing (newer devices)
fastboot getvarRetrieve device information variables
fastboot bootBoot an image without flashing
fastboot updateFlash all partitions from an update ZIP file
fastboot flashallFlash all partitions from AOSP build output
fastboot formatFormat a partition with a specified filesystem
fastboot oem device-infoDisplay bootloader and device lock status
fastboot continueContinue the boot process after fastboot operations
fastboot set_activeSet the active slot for A/B devices
repo initInitialize repo client
repo syncDownload or update source code
repo statusShow the status of repositories
repo diffShow detailed changes across repositories
repo manifestGenerate or manage manifest files
repo pruneRemove obsolete branches from repositories
repo branchesList branches across all repositories
repo startStart a new branch across repositories
repo checkoutSwitch to an existing branch across repositories
repo uploadUpload changes for review
repo abandonDelete a branch across repositories
repo diffmanifestsCompare two manifest files
repo forallExecute a command in all repositories
source build/envsetup.shInitialize build environment
lunchSelect build target
mBuild from top of source tree
mmBuild modules in the current directory
mmmBuild specified modules
makeRun the full build using make
maBuild all modules in the current directory and dependencies
tapSet up a target and prepare environment
make cleanRemove all build artifacts
m droidBuild the entire Android system
make installcleanClean installed files while preserving object files
m checkbuildVerify build configuration without building
m modulesList all available build modules
git log --onelineShow commit history in one line format
git logShow detailed commit history
git showShow details of a specific commit
git diffShow changes between commits, branches, or working directory
git statusShow the status of the working directory and staging area
git addStage changes for the next commit
git commitRecord staged changes to the repository
git pushPush local commits to a remote repository
git fetchDownload objects and refs from a remote repository
git pullFetch and merge changes from a remote repository
git branchList, create, or delete branches
git checkoutSwitch branches or restore working directory files
git mergeMerge changes from one branch into another
git rebaseReapply commits on top of another base
git resetReset current HEAD to a specified state
git revertCreate a new commit that undoes a previous commit
git cherry-pickApply a specific commit to the current branch
git cloneClone a repository into a new directory
getpropGet Android system properties
setpropSet Android system properties
dumpsysDump system service information
psList running processes on the device
topDisplay real-time process resource usage
cat /proc/*View system information from /proc filesystem
lsList files and directories on the device
dfDisplay disk usage on the device
suSwitch to superuser (root) mode
mountMount or list filesystem mounts
umountUnmount a filesystem
rebootReboot the device from the shell
killTerminate a process by PID
pidofFind the PID of a running process
uptimeDisplay system uptime and load averages
whoamiDisplay the current user identity
getenforceGet current SELinux enforcement status
setenforceSet SELinux enforcement mode
sestatusDisplay detailed SELinux status and configuration
ls -ZList files with SELinux security contexts
chconChange SELinux security context of a file or directory
restoreconRestore default SELinux security contexts
getfattrDisplay SELinux extended attributes of a file
setfattrSet SELinux extended attributes of a file
selinuxenabledCheck if SELinux is enabled on the device
checkpolicyCompile and check SELinux policy files
load_policyLoad a new SELinux policy file
ps -ZList processes with SELinux security contexts
Pro Tips
Search Tips
- • Use partial words: "repo" finds all repo commands
- • Search by function: "flash" shows flashing commands
- • Filter by category for focused results
Safety First
- • Red badges indicate destructive commands
- • Always backup before using destructive commands
- • Test commands on non-production devices first