<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Gopi Krishna on Medium]]></title>
        <description><![CDATA[Stories by Gopi Krishna on Medium]]></description>
        <link>https://medium.com/@gopikrish2000?source=rss-a798a20341a9------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*Ldpe66ny27yDKfyvQ9HyqA.jpeg</url>
            <title>Stories by Gopi Krishna on Medium</title>
            <link>https://medium.com/@gopikrish2000?source=rss-a798a20341a9------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 27 Nov 2026 22:45:16 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@gopikrish2000/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Android Apps Develop Fast(er) and Easier (saves 30 min daily) Part2]]></title>
            <link>https://medium.com/@gopikrish2000/android-apps-develop-fast-er-and-easier-saves-30-min-daily-part2-68253d9f3086?source=rss-a798a20341a9------2</link>
            <guid isPermaLink="false">https://medium.com/p/68253d9f3086</guid>
            <category><![CDATA[android-development]]></category>
            <category><![CDATA[android-app-development]]></category>
            <category><![CDATA[android]]></category>
            <category><![CDATA[android-apps]]></category>
            <category><![CDATA[androiddev]]></category>
            <dc:creator><![CDATA[Gopi Krishna]]></dc:creator>
            <pubDate>Fri, 10 May 2019 07:23:59 GMT</pubDate>
            <atom:updated>2019-05-13T18:46:53.027Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*yGXOAPnGPl1Nqo1k" /><figcaption>Develop Android Apps Fast(er) and Easier — Part 2</figcaption></figure><p>In case if you missed <strong>first part</strong> of the article, please see it here <a href="https://blog.usejournal.com/android-apps-develop-fast-er-and-easier-saves-30-min-daily-9691f0c63573"><strong>https://blog.usejournal.com/android-apps-develop-fast-er-and-easier-saves-30-min-daily-9691f0c63573</strong></a> &amp; continue with this article.</p><blockquote>Life is like a ten speed bicycle. Most of us have gears we never use.<br>Use this article to find your fastest gear.</blockquote><h3><strong>Topics</strong></h3><ol><li>Developer Assistant App ( saves 10 min daily)</li><li>Dev Tools App ( saves 2 min )</li><li>Designer Tools App ( saves 4 min )</li><li>Adb Wifi Command</li><li>More Useful Terminal Shortcuts ( saves 4 min )</li><li>Access DataBases, Shared Preferences, API calls Easy</li><li>New File Templates ( Code Easy )</li><li>Useful Live Template examples</li><li>Wait for Debugger</li><li>Opacity Index Helper</li><li>Useful Shortcuts &amp; Others</li></ol><h3>1. Developer Assistant App</h3><p>If you are in a screen &amp; u want to know which Activity or Fragment it belongs to. U can do it very easily. Install <a href="https://play.google.com/store/apps/details?id=com.appsisle.developerassistant">https://play.google.com/store/apps/details?id=com.appsisle.developerassistant</a> &amp; active it with long press on home button.</p><p>Use <strong>Hierarchy</strong> section of app n find some <strong>id -&gt; </strong>then Text Search (Edit -&gt; Find -&gt; Find in Path) in Android Studio -&gt; go to layout -&gt; Text Search again for layout file -&gt; u will land in either Fragment or Activity.</p><p>With the app u can do <strong>many more things</strong> like Measure any view width/height , <strong>Distance from Top of screen</strong>, See language translations for a string, <strong>Inspect a selected view </strong>( its color …). See 👇</p><p>This is free for 30 days but even after that u can use <strong>Hierarchy</strong> section which is most important section. I<strong> 100% recommend</strong> to install this app n try it out.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/904/1*RDUuZjgDV8Pc_JJy2QPLGw.png" /></figure><h3>2. Dev Tools App</h3><p>With this(<a href="https://play.google.com/store/apps/details?id=cn.trinea.android.developertools">https://play.google.com/store/apps/details?id=cn.trinea.android.developertools</a>) u can toggle preferences like Layout Bounds, Don’t Keep Activities, GPU Overdraw, Pointer location etc easily without searching for these preferences in Developer Options. <strong>Just single Tap</strong> to access many features.</p><p>Also it has few paid features like Activity History, Layout Inspector which we can avoid &amp; use above Developer Assistant App for these.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fL2gvcz1TzC8JUVAkWhzDQ.png" /></figure><h3>3. Designer Tools App</h3><p>This (<a href="https://play.google.com/store/apps/details?id=com.scheffsblend.designertools">https://play.google.com/store/apps/details?id=com.scheffsblend.designertools</a>) provides 2 important features <strong>Grid Overlay</strong> ( check misalign ui elements) {customize Grid size like 8dp * 16dp …} &amp; <strong>Color Picker</strong> (check on-screen color)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KJaTK_rCt9OBaQVmpiz_vw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/582/1*8qMZDAybIr5RUSw8uDEOlg.png" /></figure><h3>4. Adb Wifi Command</h3><p><strong>Forgot your Type C cable</strong>, still want to execute adb commands over office Wifi. Use below</p><pre><strong>adbwifi</strong> // after this command u can start adb commands over wifi no need of cable ( but for this command u still need usb cable once. )<br><strong>adbWifireset</strong> // resets adb over wifi</pre><h3>5. More Terminal Shortcuts</h3><p>Few of the above things like Layout Bounds, Don’t Keep Activities can also be achieved through terminal shortcuts &amp; Also many more.</p><p>Generally companies use Github for codebase &amp; use PullRequests(PR) for reviewing code changes and pushing to master branch. Below <strong>pr</strong> command is easy way to give pr’s which avoids lot of manual process.</p><pre><strong>pr   // </strong>will give PullRequest from current git branch to master github branch<br><strong>pr&lt;space&gt; dev // </strong>will give PR from current branch to development branch</pre><pre><strong>sett</strong> // (sett =&gt; settings) Toggle Layout Bounds<br><strong>sett&lt;space&gt;dont</strong> // Toggles Don&#39;t keep activities<br><strong>sett&lt;space&gt;point</strong> // Toggles Pointer location<br><strong>sett&lt;space&gt;deviceid</strong> // prints deviceId<br><strong>sett&lt;space&gt;version</strong> // prints installed app version</pre><pre><strong>checkactivity</strong> // prints all running activities + Fragments + layout<br><strong>per&lt;space&gt;&lt;PermissionName like </strong>WRITE_CONTACTS<strong>&gt; </strong>//will grant permission<br><strong>perd&lt;space&gt;&lt;PermissionName like </strong>WRITE_CONTACTS<strong>&gt; </strong>//will deny permission<br><strong>opn</strong>  // To unlock device which has pin 1234 ( change accordingly)<br><strong>lck</strong>  // To lock the device<br><strong>cd -</strong> // to go back to previous path in terminal easily<br><strong>git checkout -</strong> // will checkout previous branch easily</pre><p>To make 👆 work, Create a file in ~/.bash_profile or use ~/.bash_rc file &amp; copy paste 👇 &amp; use src ~/.bash_profile or src ~/.bash_rc to load</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/edb2e0866ea0a8ec333cc1849c3811fb/href">https://medium.com/media/edb2e0866ea0a8ec333cc1849c3811fb/href</a></iframe><p>If you use the all of above your <strong>50%</strong> problems will disappear</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Ftenor.com%2Fembed%2F13608503&amp;url=https%3A%2F%2Ftenor.com%2Fview%2Fthanos-fingers-thanos-elias-finger-heart-snap-infinity-war-gif-13608503&amp;image=https%3A%2F%2Fmedia.tenor.com%2Fimages%2F6947c6bfa0482a01def68f384962cbfb%2Ftenor.gif&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=tenor" width="600" height="400" frameborder="0" scrolling="no"><a href="https://medium.com/media/4da0bddbebf25981ae40121c4e32f289/href">https://medium.com/media/4da0bddbebf25981ae40121c4e32f289/href</a></iframe><h3>6. Access DataBases, Shared Preferences,API calls Easy</h3><p>In App you want to check whether correct/updated data is present in DB or Shared Prefs , so instead of debugging, we can use following ( for debug builds only )</p><p>a. Use <strong>Stetho</strong> (<a href="https://github.com/facebook/stetho">https://github.com/facebook/stetho</a>) where u can see <strong>DB data , Shared Prefs</strong>(Local Storage)<strong>, Network requests, Layout &amp; Activity Stacks</strong>(Elements Tab)<strong> </strong>using Chrome browser inspect devices. You can also run DB select queries to get appropriate data.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/838/1*5BKedmOn0VXp4RRJx0CYQw.png" /><figcaption>DB inspection through Stetho</figcaption></figure><p>b. Use Studio <strong>Device File Explorer Tab</strong> -&gt;/data/data/&lt;appId like com.abc.def&gt;/databases/abc.db -&gt; export file &amp; open with software like SqlliteBrowser to check db entries. Similarly u can check SharedPrefs from /data/data/&lt;appId like com.abc.def&gt;/shared_prefs/</p><h3>7. New File Templates ( Code Easy )</h3><p>New file which we create generally are Activity, Fragment , Adapter, Singletons (simply use Kotlin object keyword), Layouts. See Below Images</p><p>a. Create Activity given in Studio itself with RightClick-&gt;New-&gt; Activity -&gt; Empty Activity</p><p>b. Create Fragment as well given in Studio with New -&gt; Fragment -&gt; Blank Fragment</p><p>c. For Recyclerview Adapters use 👇 which supports item click &amp; Item creation in Single Click. <strong>Add this</strong> with New-&gt;Edit File Templates -&gt; Files Tab -&gt; Plus click &amp; paste below with a name like RecyclerAdapterKt . Use this (after adding ) by New-&gt;RecyclerAdapterKt -&gt; Fill FileName,ClassName… thats it.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/5eaca28fae21a72ebf7c718181880ac8/href">https://medium.com/media/5eaca28fae21a72ebf7c718181880ac8/href</a></iframe><p>Java Version of Recyclerview adapter is 👇. Just paste this instead</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/8e3a1ba391d2f411f28c3fa20a978aac/href">https://medium.com/media/8e3a1ba391d2f411f28c3fa20a978aac/href</a></iframe><p>You can create any other classes similar to above ( just add variable logic with apache velocity )</p><p>d. For layouts use New -&gt; XML -&gt; Layout XML File . You can also update this default templete via New-&gt;Edit File Template -&gt; Other Tab -&gt; layoutResourceFile.xml -&gt; add what ever else u want for default layouts like TextViews , ImageViews …</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zroiK-Uu_vU4Xqw97Xs65Q.png" /><figcaption>Create Empty Activity File Template + RecyclerAdapterKt</figcaption></figure><h3>8. Useful Live Templates</h3><p>For coding i suggest use <strong>Kotlin</strong> as much as possible which has shorter syntax &amp; very less verbose. For layouts I still prefer writing it in xml than drag n drop which is still not perfect. Use 👇 in layout xml coding</p><pre><strong>atv</strong> // create TextView with Id, text, color, size<br><strong>aet</strong> // create EditText with Id, text, color, size<br><strong>aiv</strong> // create ImageView with Id, Source<br><strong>acons</strong> // create ConstraintLayout with Id<br><strong>ahcenter</strong> // constraintLayout align center horizontally<br><strong>acenter</strong>  // constraintLayout align center horizontally &amp; vertically<br><strong>amal</strong>  // adds margin in all sides<br><strong>apal</strong>  // adds padding in all sides<br><strong>acv</strong>  // align center vertical in RelativeLayout<br><strong>ach</strong>  // align center horizontal in RelativeLayout</pre><p>Add Below by Preferences -&gt; Live Templates -&gt; click + -&gt;Template Group -&gt; Name it AndroidXML -&gt; click + -&gt; Live Template -&gt; &lt;abbrevation like 👆atv , aet …&gt; , (Define Scope below select XML) &amp; Template Text 👇 . { Also do Edit Variables -&gt; put default values for variables like $text$ =&gt; default value as “abc” }</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/b774d6cbf3aa411d8746442797ee2d2e/href">https://medium.com/media/b774d6cbf3aa411d8746442797ee2d2e/href</a></iframe><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AAWqeQzV_zKcCwjPRLjAxQ.png" /><figcaption>Live Templates addition example</figcaption></figure><h3>9. Wait for Debugger</h3><p>When you want to debug something in app which happens just after app launch like some code in Application onCreate()… You have 2 options</p><p>a. Click on Debug App button of Studio, Which will build the app n waits for debugger in Application code. If your <strong>build time is more</strong> then this is painful.</p><p>b. Instead there is option of “Wait for Debugger” in Developer options, then u enable &amp; just open app it waits until debugger is connected. After connected it will stop at debug point of Application code <strong>without building app.</strong></p><h3>10. Opacity Index Helper</h3><p>If u want to set color black(#000000) with 50% alpha for textview, instead of setting alpha 0.5 to textview , U can simply do #<strong>80</strong>000000 ( add 80 to color code ). For other alpha percentages see 👇</p><pre>Alpha% - ColorCodePrefix<br>100% — FF  95% — F2  90% — E6<br>85% — D9   80% — CC  75% — BF<br>70% — B3   65% — A6  60% — 99<br>55% — 8C   <strong>50% — 80  </strong>45% — 73<br>40% — 66   35% — 59  30% — 4D<br>25% — 40   20% — 33  15% — 26<br>10% — 1A   5% — 0D   0% — 00</pre><p>The above is useful when conditionally u want to set 50% Black or no alpha Orange then u can just set color prefixing alpha 👆 rather than handling <strong>both</strong> Alpha &amp; Color code</p><pre>textView.setAlpha(0.5); textView.setColor(“#000000) } to simply textView.setColor(“#80000000)</pre><h3>11. Useful Shortcuts &amp; Others</h3><ul><li><strong>Build as less as possible</strong> ( unless your build time is very less). As build time in companies in generally is few minutes , avoid building multiple times . Few ways to do it are</li></ul><p>a. Check your code/logic multiple times before building to avoid silly mistakes &amp; repeated building.</p><p>b. Write code in modular fashion (use MVVM) so that u can test your logic with a simple main class ( in separate IDE like Intellij Idea). So that u can test logic multiple times &amp; then paste your code to Android Studio project.</p><p>c. Build new Layouts/Animations in a Separate Android Studio sample project where build time is negligible then paste to your Main project.</p><p>d. Use existing code as much as possible which is already tested which should mostly work fine. So you avoid repeated building.</p><ul><li>Use <strong>Kotlin</strong> (than Java) which is less verbose , null safe &amp; other features which makes coding faster. See my <strong>Code Cleanup with Kotlin</strong> article <a href="https://blog.hike.in/code-clean-up-with-kotlin-87876ea2815c"><strong>https://blog.hike.in/code-clean-up-with-kotlin-87876ea2815c</strong></a></li><li>Cool plugin to convert <strong>existing layouts to DataBinding</strong> with multiple features <a href="https://plugins.jetbrains.com/plugin/9271-databinding-support">https://plugins.jetbrains.com/plugin/9271-databinding-support</a></li><li>Always check <strong>Animations/Page transitions</strong> by recording in <strong>Slow Motion </strong>which you can see how it is performing.</li><li>Bookmark frequent visiting websites like this &amp; put it in Chrome Bookmark toolbar (i know it looks bad ). This is one way u can access faster without forgetting the content.</li><li>Define Custom Lint rules to avoid general mistakes in code. See <a href="https://android.jlelse.eu/writing-custom-lint-rules-and-integrating-them-with-android-studio-inspections-or-carefulnow-c54d72f00d30"><strong>this</strong></a></li></ul><h3>Conclusion</h3><p>Hopefully, this article helped by showing many ways to make Android Development faster. Please read <a href="https://blog.usejournal.com/android-apps-develop-fast-er-and-easier-saves-30-min-daily-9691f0c63573"><strong>Part 1 article</strong></a> if not done. It take lot of effort to write an article , please 👏👏 if this is helpful.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2F1mgpdUbUyT7z0olfmq%2Ftwitter%2Fiframe&amp;url=https%3A%2F%2Fgiphy.com%2Fgifs%2Fboomerangtoons-carebears-new-carenears-care-bears-unlock-the-magic-1mgpdUbUyT7z0olfmq&amp;image=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2F1mgpdUbUyT7z0olfmq%2Fgiphy.gif&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="244" frameborder="0" scrolling="no"><a href="https://medium.com/media/8af38e1609c2b4d83e6514f4811c2215/href">https://medium.com/media/8af38e1609c2b4d83e6514f4811c2215/href</a></iframe><figure><a href="https://usejournal.com/?utm_source=medium.com&amp;utm_medium=noteworthy_blog&amp;utm_campaign=tech&amp;utm_content=guest_post_image"><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PYxBP_WV7LI6zc-zdUkNqQ.png" /></a></figure><p>📝 Read this story later in <a href="https://blog.usejournal.com/r/?url=https%3A%2F%2Fusejournal.com%2F%3Futm_source%3Dmedium.com%26utm_medium%3Dnoteworthy_blog%26utm_campaign%3Dtech%26utm_content%3Dguest_post_read_later_text">Journal</a>.</p><p>👩‍💻 Wake up every Sunday morning to the week’s most noteworthy stories in Tech waiting in your inbox. <a href="https://blog.usejournal.com/r/?url=https%3A%2F%2Fusejournal.com%2Fnewsletter%2Fnoteworthy-in-tech%2F%3Futm_source%3Dmedium.com%26utm_medium%3Dnoteworthy_blog%26utm_campaign%3Dtech%26utm_content%3Dguest_post_text">Read the Noteworthy in Tech newsletter</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=68253d9f3086" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Android Apps Develop Fast(er) and Easier (saves 30 min daily)]]></title>
            <link>https://medium.com/@gopikrish2000/android-apps-develop-fast-er-and-easier-saves-30-min-daily-9691f0c63573?source=rss-a798a20341a9------2</link>
            <guid isPermaLink="false">https://medium.com/p/9691f0c63573</guid>
            <category><![CDATA[android-apps]]></category>
            <category><![CDATA[android]]></category>
            <category><![CDATA[androiddev]]></category>
            <category><![CDATA[android-app-development]]></category>
            <category><![CDATA[android-development]]></category>
            <dc:creator><![CDATA[Gopi Krishna]]></dc:creator>
            <pubDate>Wed, 14 Nov 2018 05:39:21 GMT</pubDate>
            <atom:updated>2019-01-28T21:16:45.887Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*PhxHo93_ersEYd32" /><figcaption>Develop Android Apps Fast(er) and Easier (saves 30 min daily)</figcaption></figure><p>The current article will make android app development faster by around 30 minutes when followed completely. Using most useful Android Studio plugins, Android adb terminal shortcuts, Android Build time optimisation…Below says how to do it.</p><p>In case you didn’t read my first article <a href="https://blog.hike.in/code-clean-up-with-kotlin-87876ea2815c"><strong><em>Code Clean up with Kotlin</em></strong></a><em> </em>please read for code cleanup.</p><blockquote>We always want to write most <strong>efficient code</strong>.<br> but what most doesn’t do is <strong>Efficiency of writing</strong> such kind of code ( time taken)</blockquote><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2FnSwUTD1L8PhZK%2Ftwitter%2Fiframe&amp;url=https%3A%2F%2Fgiphy.com%2Fgifs%2Flight-shortcut-coors-nSwUTD1L8PhZK&amp;image=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2FnSwUTD1L8PhZK%2Fgiphy-downsized-large.gif&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="543" frameborder="0" scrolling="no"><a href="https://medium.com/media/447a91c1bcc54a55cdae2eecb5a9adfb/href">https://medium.com/media/447a91c1bcc54a55cdae2eecb5a9adfb/href</a></iframe><h3>Topics</h3><ol><li>Terminal Shortcuts ➿( saves 4 min )</li><li>Android Studio Plugins ( saves 5 min )</li><li>Jumpcut (saves 3 min)</li><li>BetterTouchTool (saves 2–3 min)</li><li>Git Commands with Android Studio ( saves 5–6 min)</li><li>Reduce Build time ( saves a lot 15–20 min)</li><li>Android Studio must remember shortcuts (saves 2–3 min)</li><li>File Templates ( saves a lot 10 minutes )</li><li>Third Party Libraries &amp; Others</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*xQxOWmlFMY1D-rJ6" /><figcaption>Develop Android Apps faster and save time</figcaption></figure><p><em>Using MAC OS as reference to below, feel free to change based on Operating System</em></p><h3>1. Terminal Shortcuts</h3><p>There are many things which we can do it better &amp; faster through terminal commands but main problem is <strong>typing</strong> big commands .</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2Fo0vwzuFwCGAFO%2Ftwitter%2Fiframe&amp;display_name=Giphy&amp;url=https%3A%2F%2Fgiphy.com%2Fgifs%2Fcat-hacker-webs-o0vwzuFwCGAFO&amp;image=https%3A%2F%2Fmedia0.giphy.com%2Fmedia%2Fo0vwzuFwCGAFO%2Fgiphy.gif&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="435" frameborder="0" scrolling="no"><a href="https://medium.com/media/1579b0cd36f6b88b5759074002814945/href">https://medium.com/media/1579b0cd36f6b88b5759074002814945/href</a></iframe><p>Also when building huge project through Android Studio Green button, it takes <strong>lot of RAM</strong> also causes it to <strong>stuck</strong> few times. So building apps using default terminal, Studio terminal or <a href="https://iterm2.com/"><em>iTerm2</em></a><em> </em>is better.</p><p>We usually do following for App like Install , Uninstall , Start , Stop , Clear Data, Navigate folders, Check crash logs &amp; more .</p><pre>Use in terminal following commands<strong><br>bld</strong>   // to Build with Debug flavor then install App then start it<br><strong>bld</strong>&lt;space&gt;<strong>c </strong>// clean -&gt;Build with debugFlavor-&gt;install-&gt;start it<br><strong>bldu</strong>  // to Uninstall App then Build with Debug flavor then install App &amp; then start it<br><strong>ins</strong> <em>&lt;pathToApk.apk&gt;</em> // Uninstall App then install with apk path<br><strong>upg</strong> <em>&lt;pathToApk.apk&gt;  // </em>Upgrade app without uninstalling earlier one<br><strong>upglatest</strong> // Upgrade app with latest updated apk in current folder &amp; Starts the app. Useful when apk is build but forgot to connect device.<br><strong>logs</strong>  // print only crash logs of the device<br><strong>gitrev</strong> // revert your last commit from your current Git branch <br><strong>gitcurrent</strong> // copies current Git branch name to your Clipboard<br><strong>gitdelbranch</strong> // deletes Git local branches of given pattern like abc<br><strong>uns</strong> // to uninstall ;  <strong>clr</strong> // for clear data ; <strong>stp</strong> // force stop app<br><strong>sta</strong> // to start App<br><strong>opent</strong> <em>&lt;fileName&gt;</em> // open file in TextEdit rather than vim<br><strong>l // </strong>cd.. ;<strong> ll</strong> // cd ../..  ; <strong>lll</strong> // cd ../../..</pre><p>If u r working on <strong>multiple apps simultaneously</strong> instead of changes .bash_rc file every time. u can do below ( This will change only in that terminal tab)</p><pre><strong>updateappid</strong> com.mycurrentotherapp.def // update other appId<br><strong>updatemainactivity</strong> com.mycurrentotherapp.def.MainActivity<br><strong>updatebuildtype</strong> iR  // <em>optional</em> use this only when u want to change build variant type , here changing it to <em>installRelease</em> from Debug<br><strong>printvariables </strong>// will print current state of above variables.</pre><pre>After doing updateappid ... u can use above commands <strong>bld , bldu , sta</strong> ... which will work on new app instead of old defined in bash_rc</pre><p>Other helpers in terminal to make it faster ( using Android Studio terminal)</p><pre><strong>option(alt) + delete</strong> // deletes a word ( not a letter )<br><strong>fn + left/right arrow</strong> // moves to start/end of current line<br><strong>esc + wait 50ms + B</strong> // moves cursor a word backwards<br><strong>esc + wait 50ms + F</strong> // moves cursor a word forward<br><strong>c</strong> // clear screen  <strong>o</strong> // to open finder window in current path<br>use l&#39;s to navigate back (<strong>l </strong>cd.. <strong>ll </strong>cd../.. )<br><strong>copypath</strong> // copy current path</pre><p>To make 👆 work, Create a file in ~/.bash_profile or use ~/.bash_rc file &amp; copy paste 👇 &amp; use src ~/.bash_profile or src ~/.bash_rc to load</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/c34e75bc2ee2b28e021ac493341a18de/href">https://medium.com/media/c34e75bc2ee2b28e021ac493341a18de/href</a></iframe><h3>2. Android Studio Plugins</h3><p>Few plugins which help immensely to made development faster.</p><p>a. <a href="https://plugins.jetbrains.com/plugin/7658-android-drawable-importer"><strong>AndroidDrawableImporter</strong></a><strong> </strong>with this , just select a ZIP which has pngs in all resolutions like hdpi, xhdpi … , it <strong>auto imports</strong> to Android Studio in <strong>single click</strong>. Also u can <strong>import Android Material Icons </strong>in a single click</p><p>b. <a href="https://plugins.jetbrains.com/plugin/9788-biu"><strong>Biu</strong></a><strong> </strong>can <strong>compress/convert to webp </strong>any image in <strong>single click</strong>. (right click on image -&gt; Compress/ convert to Webp ) {powered by <em>tinypng.com</em>}</p><p>c. <a href="https://plugins.jetbrains.com/plugin/7595-android-code-generator"><strong>Android Code Generator</strong></a> with this, u just write the layout xml then u can generate Activity , Fragment , Adapter code in a <strong>single click </strong>in java. <a href="https://plugins.jetbrains.com/plugin/11204-android-findviewbyid-support"><strong>FindViewById</strong></a><strong> </strong>for id generation in java n kotlin.</p><p>d. <a href="https://plugins.jetbrains.com/plugin/9862-custom-postfix-templates"><strong>Custom Postfix Templates</strong></a><strong> </strong>this adds custom postfix templates which are very useful. U can create name.isNullReturn &amp; tab converts to if(name == null) Log.d(&quot;TAG&quot;, &quot;name is null); return;</p><p>e. <a href="https://plugins.jetbrains.com/plugin/7654-gsonformat"><strong>GsonFormat</strong></a><strong> </strong>paste a json this will create classes &amp; Inner classes for you with @SerializeName as well for Java . For Kotlin use <a href="https://plugins.jetbrains.com/plugin/9960-json-to-kotlin-class-jsontokotlinclass-"><strong>JsonToKotlinClass</strong></a></p><p>f. <a href="http://www.jimumirror.com/"><strong>Jimu Mirror</strong></a> updates layout, animation changes in real-time as you code ( like React ). See this <a href="https://www.youtube.com/watch?feature=player_detailpage&amp;v=3adPncFr9Gc">video</a>.</p><p>f. Now <strong>Automatic Parcelable generation </strong>is present in Studio(3.0+) itself in contextual action 💡 for both Java &amp; Kotlin.</p><p>There are others like <a href="https://plugins.jetbrains.com/plugin/7856-adb-wifi"><strong>Adb Wifi</strong></a>, <a href="https://plugins.jetbrains.com/plugin/4455-key-promoter">KeyPrompter</a> (for prompting keyboard shortcuts) , <a href="https://plugins.jetbrains.com/plugin/7578-adbcommander-for-android">AdbCommander</a>, <a href="https://plugins.jetbrains.com/plugin/10080-rainbow-brackets">RainbowBrackets</a>, <a href="https://plugins.jetbrains.com/plugin/7086-acejump">AceJump</a> (easy caret movement), <a href="https://plugins.jetbrains.com/plugin/2162-string-manipulation">String Manipulation</a> (to multiple CASES) . By doing above u’ll feel like</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2FeW3QwuAfmpGne%2Ftwitter%2Fiframe&amp;url=https%3A%2F%2Fgiphy.com%2Fgifs%2Feasy-covergirl-mootiful-eW3QwuAfmpGne&amp;image=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2FeW3QwuAfmpGne%2Fgiphy-downsized-large.gif&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="435" frameborder="0" scrolling="no"><a href="https://medium.com/media/19a0aeeb0a5235016997da42c9762f29/href">https://medium.com/media/19a0aeeb0a5235016997da42c9762f29/href</a></iframe><h3>3. Jumpcut — Multi copy tool</h3><p>The most &amp; the frequent thing every developer does is <strong>copy &amp; paste </strong>. There are few problems with it</p><p>a. Only single copy allowed i.e <strong>copy then paste</strong> works fine but <strong>copy1 copy2 copy3 then paste1 paste2 paste3</strong> doesn’t work , which is needed many times</p><p>b. I closed my web page some 30 min back , I copied something what is it? i.e you need the list of all the items which are copied, so that u can use it later.</p><p>c. <strong>Copy source</strong> can be anything from Slack, Browser to Android Studio… So I need a system wide utility not a plugin in Android Studio …</p><p>Above all problems is solved by simple software like <a href="http://jumpcut.sourceforge.net/"><em>Jumpcut</em></a> for MAC &amp; <a href="https://sourceforge.net/projects/clipjump/"><em>ClipJump</em></a> for windows. For convenience keep Command + Shift + V as shortcut for paste popup. Copy u can do normally.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/340/1*_wSoxPKAn9he_miQOmozAg.png" /><figcaption>Jumpcut paste popup</figcaption></figure><h3>4. BetterTouchTool</h3><p>One more frequent thing every one does in Android Studio is Switch between code tabs, Close tabs , Go back to last edited location… So install <a href="https://folivora.ai/">BetterTouchTool</a> with this u can do literally, any thing on Mac as easy as</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2FQoNiidrKZ7qz6%2Ftwitter%2Fiframe&amp;url=https%3A%2F%2Fgiphy.com%2Fgifs%2Flady-problem-noodles-QoNiidrKZ7qz6&amp;image=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2FQoNiidrKZ7qz6%2Fgiphy.gif&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="556" frameborder="0" scrolling="no"><a href="https://medium.com/media/e97b5317a063cb4d6cdd58500f9627b1/href">https://medium.com/media/e97b5317a063cb4d6cdd58500f9627b1/href</a></iframe><p>Using Tip Tap Left/Right ( 1 finger fix) to go to left / right tab . TipTap Right ( 2 finger fix) to close current tab. Snapping windows similar to Windows OS, Text replacement &amp; many more</p><p>See following articles for more clarity <a href="https://www.youtube.com/watch?v=MRhBa3-O3fM"><em>TipTap gesture</em></a><em> </em>, <a href="https://appleinsider.com/articles/18/07/20/bettertouchtool-is-the-app-the-macbook-pro-with-touch-bar-needs">https://appleinsider.com/articles/18/07/20/bettertouchtool-is-the-app-the-macbook-pro-with-touch-bar-needs</a></p><p><a href="https://www.makeuseof.com/tag/bettertouchtool-mac-productivity/">4 Ways BetterTouchTool Is the Ultimate Mac Productivity App</a></p><h3>5. Git Commands with Android Studio</h3><p>Many people has habit of commiting &amp; pushing using terminal. It’s not bad but its slow &amp; there are few problems with it . It’s very easy &amp; saves lot of time in Android Studio.</p><p>a. Check files status with git statusthen git add then git commit&amp; git push . Instead do it in <strong>single key</strong></p><p>b. Conflict Resolution is very easy with 3 way merge. <strong>UnStashing</strong> u can check changes before applying in Studio</p><p>c. Studio provides Reformatting code , Organize Imports , Check Todo’s , Perform code analysis &amp; many more which <strong>cannot</strong> be done normally using command line unless there is a pre-hook commit script …</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PPKTpIJ365cZ_VwQjr81pw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*sXHrV0F4092obaLLtTS18g.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lNWlQkhJcg4UmH3_ZsxKYQ.png" /></figure><h3>6. Reduce Build time</h3><p>There are few ways to reduce build time. See 👇</p><p>a. For testing always use <a href="https://developer.android.com/studio/build/build-variants">build variant </a>which is debug with minifyEnabled false &amp; shrinkResources false as minify &amp; shrink takes adds lot to build time.</p><p>b. Add following to gradle.properties if not added to make build faster</p><pre><strong>org.gradle.daemon</strong>=<strong>true<br>org.gradle.parallel</strong>=<strong>true<br>org.gradle.jvmargs</strong>=<strong>-Xmx3g -XX:MaxPermSize=2048m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8<br>org.gradle.caching </strong>= <strong>true<br>org.gradle.configureondemand</strong>=<strong>true <br>android.enableBuildCache</strong>=<strong>true</strong></pre><p>c. For your test <a href="https://developer.android.com/studio/build/build-variants">build variant/product flavour</a> do following to decrease time</p><pre>customBuildFlavor {<br>   <strong>minSdkVersion</strong> 21   // makes build time slightly faster<br>    aaptOptions {<br>       cruncherEnabled = false<br>   }<br>   dexOptions {<br>       preDexLibraries = true<br>   }<br>   <strong>resConfigs</strong>(&quot;en&quot;, &quot;xxhdpi&quot;) // specify a default language &amp; resolution for faster packing of build<br>}</pre><p>d. This is slightly hacky but works , if your company is using lot of GitHub tracking libraries like DexCount ( for counting methods ) , other Functional testing libraries like Jacoco , Spoon etc . <strong>Comment</strong> out all (which are not directly effecting the App code ) <em>apply plugin &amp; its references</em> but don’t Git push file to your server branch .</p><p>Just use the above to build, you will be surprised to see build time will <strong>decrease by 30 seconds</strong> on every build.</p><h3>7. Android Studio must remember shortcuts</h3><p>Few shortcuts which every developer must know. Avoid using <strong>Double Shift </strong>in Android Studio as much as possible (bcoz it is slow) , instead use appropriate shortcut of each. For convenience change shortcuts to below in Android Studio-&gt;Preferences -&gt; Keymap -&gt;Search -&gt; Add keyboard shortcut</p><pre>. Open any file ( Command + Shift + R )<br>. Find in path ( Command + Shift + H ) { for string search like &quot;abc&quot; }<br>. Close All tabs ( Command + Shift + W )<br>. Recent files ( Command + E )<br>. File Structure ( Command + O )  { Go to method name inside a file, no Command + F here, which is slow}<br>. Navigate -&gt; Declaration ( F1 ) // go to declaration of variable or method call hierarchy<br>. Navigate -&gt; Back ( F2 )  // go back to last cursor position<br>. Navigate -&gt; Forward ( F3 ) // go forward from last cursor position<br>. Run -&gt; Step into (F5) // Debugging go into the method<br>. Run -&gt; Step over (F6) // Debugging go to next line of the method<br>. Run -&gt; Resume Program (F8) // Debugging stop at next debug point</pre><pre>Optional Good to have :<br>. VCS -&gt; Git -&gt; Commit (Command + Shift + L) <br>. VCS -&gt; Git -&gt; Pull (Command + Shift + ;)<br>. VCS -&gt; Git -&gt; Unstash (Command + Shift + &quot;)</pre><p>If you see carefully above most of above shortcuts u can use just with your <strong>left hand </strong>(single ✋). Most of the times we want see declaration of variable or call hierarchy of a method use <strong>F1</strong> for it. Also to go 🔙 to last cursor location use <strong>F2</strong>. Go forward use <strong>F3</strong>. For touch bar mac laptops see <a href="https://www.techrepublic.com/article/how-to-permanently-display-the-function-keys-for-certain-apps-in-the-macbook-pro-touch-bar/"><em>Display function keys for certain apps</em></a><em> </em>to make function keys default in touch bar mac. You can convert above to gestures using point 4 <a href="https://folivora.ai/"><em>BetterTouchTool</em></a><em> as well.</em></p><h3>8. File Templates</h3><p>Instead of creating same files like RecyclerViewAdapter , Fragments , DialogFragments , Dialogs … <strong>again &amp; again</strong>. Add it as a template saves lots of time, frustration &amp; will create it in a <strong>single click</strong>.</p><ul><li><a href="https://android.jlelse.eu/supercharging-your-app-development-speed-with-custom-file-templates-3e6acb6db6c3">Supercharging your app development speed with custom file templates</a></li><li><a href="https://medium.com/google-developers/writing-more-code-by-writing-less-code-with-android-studio-live-templates-244f648d17c7">Writing More Code by Writing Less Code with Android Studio Live Templates</a></li></ul><h3>9. Others</h3><ul><li>U can develop faster using <a href="https://www.bignerdranch.com/blog/android-studio-live-templates/">Live Templates</a> , <a href="https://www.bignerdranch.com/blog/android-studio-live-templates/">Live &amp; Surround templates</a> , <a href="https://plugins.jetbrains.com/plugin/9862-custom-postfix-templates">PostFix Completions</a> , <a href="https://www.jetbrains.com/help/idea/using-macros-in-the-editor.html">Macros</a> . see 👆</li><li><a href="https://www.mockable.io/">https://www.mockable.io</a> for <strong>mock json data</strong> from server url</li><li><a href="http://lorempixel.com/300/300/sports/">http://lorempixel.com/300/300/sports/</a> for <strong>random images</strong> of different sizes to use in your app.</li><li><a href="http://objgen.com/json?demo=true">http://objgen.com/json?demo=true</a> to <strong>generate json</strong> easily.</li><li>Debug App Database, SharedPreferences &amp; Network requests… using <strong>Stetho </strong>(<a href="https://github.com/facebook/stetho">https://github.com/facebook/stetho</a>)</li><li>Testing <strong>Deeplinks</strong> with complex data <strong>without escaping</strong> use this trick(additional ‘ at <em>am &amp; end ){Replace url inside “}</em></li></ul><pre>adb shell <strong>&#39;</strong>am start -a android.intent.action.VIEW -d &quot;company://product/capture?a=1&amp;b=2&amp;data={&#39;abc&#39;:&#39;first&#39;,&#39;def&#39;:&#39;second&#39;}&quot;<strong>&#39;</strong></pre><ul><li><a href="https://blog.mindorks.com/awesome-android-open-source-libraries-56a008c776c0">https://blog.mindorks.com/awesome-android-open-source-libraries-56a008c776c0</a> for awesome <strong>android open source libraries</strong>.</li><li>Make Android Studio faster by providing more RAM to it , indirectly make your browsers take less RAM by using memory optimisers like <a href="https://chrome.google.com/webstore/detail/the-great-suspender/klbibkeccnjlkjkiokjodocebajanakg?hl=en"><strong>Great Tab Suspender</strong></a><strong> </strong>for Chrome.</li><li>Configure Android Studio to <strong>show line numbers</strong> &amp; <strong>method separators</strong> for cleaner &amp; easier code readability ( Editor -&gt; General -&gt; Appearance )</li></ul><blockquote>Good requires motivation, Great requires obsession. You should be very conscious of every time saving trick to achieve fastness</blockquote><h3>Conclusion</h3><p>Hopefully, this article helped by showing many ways to make Android Development faster. I have given all my information which I’m using from <strong>few years</strong>. If you find this article useful <strong>Please 👏 👏</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*grg_TgEcKjPxEtrE" /><figcaption>Please Clap</figcaption></figure><figure><a href="https://usejournal.com/?utm_source=medium.com&amp;utm_medium=noteworthy_blog&amp;utm_campaign=guest_post_image"><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*f2IVAl0TbsfES9cFGYr40g.png" /></a></figure><p>📝 Read this story later in <a href="https://usejournal.com/?utm_source=medium.com&amp;utm_medium=noteworthy_blog&amp;utm_campaign=guest_post_read_later_text">Journal</a>.</p><p>🗞 Wake up every Sunday morning to the week’s most noteworthy Tech stories, opinions, and news waiting in your inbox: <a href="https://usejournal.com/newsletter/?utm_source=medium.com&amp;utm_medium=noteworthy_blog&amp;utm_campaign=guest_post_text">Get the noteworthy newsletter &gt;</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9691f0c63573" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>