Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Few command line tools for help Android development

1,265 views

Published on

Introduce few command line tools for Android development.

Published in: Internet
  • Be the first to comment

Few command line tools for help Android development

  1. 1. Few command line tools for help android development The slide for Shinjuku.aar by tomorrowkey July. 28, 2016 ©tomorrowkey 2016 1
  2. 2. Personal introduction ©tomorrowkey 2016 2
  3. 3. Who am I? 4 @tomorrowkey 4 http://tomorrowkey.hatenablog.jp/ 4 Work for Cookpad as Android and Rails Engineer 4 Pokémon GO 4 Lv13 Team Mystic ! ©tomorrowkey 2016 3
  4. 4. Google Play Few apps published on Google Play. https://play.google.com/store/apps/developer? id=tomorrowkey ©tomorrowkey 2016 4
  5. 5. At first, I have a question. ©tomorrowkey 2016 5
  6. 6. Do you guys use command line tools for Android development? ©tomorrowkey 2016 6
  7. 7. Reliable 7 buddies ©tomorrowkey 2016 7
  8. 8. 4 adb-peco 4 pidcat 4 installapp 4 uninstallapp 4 clearapp 4 screenshot 4 notifier-plugin ©tomorrowkey 2016 8
  9. 9. Choose a device by peco when you fire adb command ©tomorrowkey 2016 9
  10. 10. Have you face following suck message? ! more than one device and emulator You don't have to care since you use adb-peco. ©tomorrowkey 2016 10
  11. 11. Installation Re-implements with Ruby ✨ gem install adb-peco It may not work on Windows... Welcome to contribute on https://github.com/ tomorrowkey/adb-peco ©tomorrowkey 2016 11
  12. 12. Show logcat with color ©tomorrowkey 2016 12
  13. 13. Before ©tomorrowkey 2016 13
  14. 14. After ©tomorrowkey 2016 14
  15. 15. Features Show all logs with color pidcat Specify application id like following. pidcat jp.tomorrowkey.android.hogeapp ©tomorrowkey 2016 15
  16. 16. Tips pidcat can be received logcat from pipe input. So I combinate pidcat, adb-peco, pm and peco. function logcat() { local package=$(adb-peco shell pm list packages | sed s/package:// | peco) adb-peco logcat | pidcat $package } ©tomorrowkey 2016 16
  17. 17. Installation brew install pidcat https://github.com/JakeWharton/pidcat ©tomorrowkey 2016 17
  18. 18. And the others. ©tomorrowkey 2016 18
  19. 19. installapp, uninstallapp, clearapp, screenshot alias installapp='find ./ -name *.apk | peco | xargs adb-peco install' alias uninstallapp='adb-peco shell pm list packages | sed s/package:// | peco | xargs adb-peco uninstall' alias screenshot='adb-peco screenshot2 $HOME/Desktop/screenshot.png && open $HOME/Desktop/screenshot.png' alias clearapp='adb-peco shell pm list packages | sed s/package:// | peco | xargs adb-peco shell pm clear' ©tomorrowkey 2016 19
  20. 20. Messy ! ©tomorrowkey 2016 20
  21. 21. Assemble in a command ! ©tomorrowkey 2016 21
  22. 22. android-command-line-tools android-command-line-tools install android-command-line-tools uninstall android-command-line-tools screenshot android-command-line-tools clear ©tomorrowkey 2016 22
  23. 23. +2 android-command-line-tools screenrecord # android-command-line-tools launch avd ©tomorrowkey 2016 23
  24. 24. Installation gem install android-command-line-tools https://github.com/tomorrowkey/android-command- line-tools This tool is still in under development. It might be changed without notice. ©tomorrowkey 2016 24
  25. 25. Alias This command is too long for daily use. recommend to make an alias like following. alias hoge='android-command-line-tools' If you invent a good alias name. let me know ! ©tomorrowkey 2016 25
  26. 26. Cats go meow when build completed ! ©tomorrowkey 2016 26
  27. 27. Android apps build is SOOOOOOOOOOO LONG !©tomorrowkey 2016 27
  28. 28. You guys busy on Twitter and Pokémon while building app anyway ! ©tomorrowkey 2016 28
  29. 29. It tell us that the build completed in the visual ! and at the hearing " ©tomorrowkey 2016 29
  30. 30. Installation (1/2) build.gradle buildscript { repositories { mavenCentral() } dependencies { classpath 'jp.tomorrowkey.gradle.notifier:notifier-plugin:1.0.1' } } app/build.gradle apply plugin: 'notifier-plugin' ©tomorrowkey 2016 30
  31. 31. Installation (2/2) notifier.properties voice.enabled=true voice.name=Alex notificationCenter.enabled=true sound.enabled=false sound.url=file:///Users/tomorrowkey/Desktop/meow.mp3 beep.enabled=false beep.count=5 ©tomorrowkey 2016 31
  32. 32. That's all! Conclusion ©tomorrowkey 2016 32
  33. 33. Conclusion Android app development sometime annoy me. Also I continue to make helpful tools. Let me know if you have a trouble. ©tomorrowkey 2016 33

×