在Android中的文件中可以设置很多属性,其中有一项是debuggable属性,意为“可调试”,有true和false两种模式。
默认情况下我们都是需要设置的,如果打包的是debug版本的apk文件,那么这个debuggable属性就自动设置为true,反之,如果打包的是release版本的apk文件,那么这个debuggable属性就自动设置为false。
换而言之,就是这个属性不需要我们进行手动配置。
贴上官方文档说明:
Avoid hardcoding the debug mode, leaving itout allows debug and release builds to automatically assign one.
It is best to leave out theandroid:debuggable attribute from the manifest. If you do, then the tools willautomatically insert android:debuggable=true when building APK to debug on anemulator or device. And when you perform a release build such as Exporting APK,it will automatically set it to false.
If on the other hand you specify a specificvalue in the manifest file, then the tools will always use it. This can lead toaccidentally publishing your app with debug information.