Skip to content

Instantly share code, notes, and snippets.

View mrk-han's full-sized avatar
💭
Looking for new opportunities!

Mark Han mrk-han

💭
Looking for new opportunities!
View GitHub Profile
@mrk-han
mrk-han / ViewGroupUtils.java
Created July 31, 2019 02:03 — forked from orip/ViewGroupUtils.java
Find all Android views tagged with a given value. Similar to document.getElementsByClassName in JavaScript/DOM to find elements with a given class. Based on this StackOverflow answer by Shlomi Schwartz: http://stackoverflow.com/a/8831593/37020
package com.onavo.android.common.ui;
import android.view.View;
import android.view.ViewGroup;
import java.util.LinkedList;
import java.util.List;
/**
* Based on http://stackoverflow.com/a/8831593/37020 by by Shlomi Schwartz
@mrk-han
mrk-han / android_grpc_sample_documentation.md
Last active February 27, 2024 06:47
how to use experimental gRPC to control android emulators [Rough fork of GRPC MD from AOSP]

Emulator over gRPC Examples

Thanks to Erwin Jansen for these samples and this readme. (I just formatted this and threw it in a gist to make it more shareable and readable)

Samples can be downloaded here: https://android.googlesource.com/platform/external/qemu/+/refs/heads/emu-master-dev/android/android-grpc/docs/grpc-samples

Caveats: Experimental feature!!

This is currently an experimental feature, and as such there are some things lacking that might be important if you want to use this in production:

@mrk-han
mrk-han / Android-Resources.md
Last active August 21, 2020 07:55
Android Resources

A mind dump of resources for learning Android Development

Brief Overview

I learned from a combination video tutorials (CasterIO) , online classes (Udacity) , blogs (medium posts) , forums (/r/androiddev) , and the developer.android documentation, codelabs, and javadocs. Also, I follow anyone I learned from on Twitter so I could get more insight into the android ecosystem. I got a copy of the Android Big Nerd Ranch book but I’m not much of a book person when I’m on my computer, I mostly just google and SO stuff instead.

Udacity Courses

I got my start learning through Udacity’s courses which were made in partnership with Google

@mrk-han
mrk-han / emulator-install-using-avdmanager.md
Last active May 1, 2024 21:12
Installing and creating Emulators with AVDMANAGER (For Continuous Integration Server or Local Use)

Install and Create Emulators using AVDMANAGER and SDKMANAGER

TL;DR

For an emulator that mimics a Pixel 5 Device with Google APIs and ARM architecture (for an M1/M2 Macbook):

  1. List All System Images Available for Download: sdkmanager --list | grep system-images

  2. Download Image: sdkmanager --install "system-images;android-30;google_atd;arm64-v8a"

@mrk-han
mrk-han / ubuntu-android.txt
Last active September 20, 2022 23:52
Setting up Linux Environment to run Espresso tests on Android x86 Emulator
# Android w/ x86 Emulator
## SETUP
sudo -S apt-get update && sudo apt-get upgrade -y
sudo -S apt-get install zip unzip wget git curl vim openjdk-8-jdk qemu-kvm -y
sudo -S adduser $USER kvm
mkdir -p Android/platforms
wget https://dl.google.com/android/repository/sdk-tools-linux-4333796.zip
unzip sdk-tools-linux-4333796.zip -d Android/
@mrk-han
mrk-han / gist:4a8d59a3b7a3eb7883cb804632e6640f
Last active April 7, 2021 20:36
A rough documentation of setting up MERN environment on a Fresh Centos 7 Server on Digital Ocean

Context

Reverse Proxy?

Or just use Node

  • We had the opportunity of setting up a fresh Digital Ocean server running CentOS 7, and opt'd for this for simplicity and for the fun experience of learning how to set up a fresh CentOS 7 Server to be used with the MERN stack.
  • In our scenario, Node can listen on port 80 and we should be good to go...
@mrk-han
mrk-han / index.md
Created February 27, 2018 01:58 — forked from ericandrewlewis/index.md
C++ Pointer Tutorial

C++ Pointer Tutorial

Because pointers can be ugh

"Regular" variables (not pointers)

To understand a pointer, let's review "regular" variables first. If you're familiar with a programming language without pointers like JavaScript, this is what you think when you hear "variable".

When declaring a variable by identifier (or name), the variable is synonymous with its value.

@mrk-han
mrk-han / git-cheat-list.md
Created December 3, 2017 21:16
Git cheat list