» android の記事

Open Terminal
~/Library/Android/sdk/platform-tools/adb shell ps | grep <com.xxx.xxx>
to get the pid of the packagname application
And open android studio
On logcat section tick on the pull down menu of regex
Select Edit Filter Configuration
and insert pid, PS: using package name to search is not work well with non-compiled project via android studio.

~ nox logcat ~

connie 2020.08.18 | android | | No Comments

cmd
nox_adb logcat>logcat.log

Reference Link:
https://developer.android.com/google/play/billing/realtime_developer_notifications

Step 1 Setup Cloud Service

https://console.cloud.google.com/cloudpubsub/
=>create topic
=>projects/xxxxxxxxxxxxx/topics/mgotest
=>Google-managed key
=>create topic

=>create subscriptions
subscription ID

Delivery type
Push

Push endpoint
https://xxxxxxxxxx/ASTest.php

Step 2 Pair up the project with Google play consol

Google Play Console.
=>select App
=>Developerment tools
=>Services & Apis
=>Real-time developer notifications
Topic name=>projects/ xxxxxxxxxxxxx /topics/mgotest

~ google console keystore to facebook keyhash ~

connie 2019.10.08 | android | | No Comments

convert sha-1 hash (from google) to base64 hash for facebook

install xxd in centos
yum install vim-common

echo 33:4E:48:84:19:50:3A:1F:63:A6:0F:F6:A1:C2:31:E5:01:38:55:2E | xxd -r -p | openssl base64

Output:
M05IhBlQOh9jpg/2ocIx5QE4VS4=

copy this to facebook console

1)clean project rebuild

2)restart android studio

3)File->Invalidate cache and restart

4)open android terminal
first time use Gradle have to change the permission
chmod +x gradlew
./gradlew compileDebugSource –stacktrace -info
then see the error for details

Please add this to AndroidManifest.xml:
<uses-library
android:name="org.apache.http.legacy"
android:required="false" />

~ android logcat missing filter gone ~

connie 2019.07.29 | android | | No Comments

-logcat setting change it to floating mode and disable the floating mode, and double click the logcat bar to resize the logcat, it i will appear again

-if still cannot fix restart android studio and retry

~ apk check package name and permission ~

connie 2019.07.15 | android | | No Comments

aapt.exe dump badging [path-to-apk]

~ Android studio create an aar library ~

connie 2019.07.08 | android | | No Comments

Create a project
File->new->new module->android Library

create a class , and modify string.xml for testing

之後打開gradle

assemble then it will create 2 aar

Create a new project>change to project view, insert the aar file to app>libs folder

and change the gradle(apps)

try to execute the apps

~ fix Mac terminal cannot use aapt ~

connie 2019.06.21 | android, Mac OSX | | No Comments

cd ~
touch .bash_profile
nano .bash_profile

AAPT_HOME=/Users/xxx/Library/Android/sdk/build-tools/28.0.3
export AAPT_HOME
export PATH=$PATH:$AAPT_HOME

« Previous Page | HOME |

Smiley face

March 2024
S M T W T F S
 12
3456789
10111213141516
17181920212223
24252627282930
31