Skip to content

Instantly share code, notes, and snippets.

View NotWoods's full-sized avatar

Tiger Oakes NotWoods

View GitHub Profile
@NotWoods
NotWoods / feedly.ompl
Created August 31, 2020 23:53
Tech feeds I follow
<?xml version="1.0" encoding="UTF-8"?>
<opml version="1.0">
<head>
<title>Tiger subscriptions in feedly Cloud</title>
</head>
<body>
<outline text="personal blogs" title="personal blogs">
<outline type="rss" text="Ada Rose Cannon" title="Ada Rose Cannon" xmlUrl="https://ada.is/feed" htmlUrl="https://ada.is"/>
<outline type="rss" text="Adam Speakman" title="Adam Speakman" xmlUrl="http://speakman.net.nz/atom.xml" htmlUrl="http://adamsp.github.com/speakman-website/"/>
@NotWoods
NotWoods / README.md
Last active January 19, 2020 06:12
U-Pass icon

U-Pass icon seen on https://upassbc.translink.ca/fs/. On the site, its a massive base64 svg. It's much smaller as a PNG, so perhaps a PNG with srcset would be more appropiate.

@NotWoods
NotWoods / adb-all.sh
Created September 3, 2019 21:55
Run ADB command on all connected devices
# Use `source adb-all.sh` to get the adb-all command in the shell
# Run adb command on all connected devices
function adb-all() {
# adb devices -l: Print all devices, along with connected ports. Works with devices missing a serial no.
# egrep '(device|emulator) usb': Select lines with devices listed. (ex: SERIAL device usb:2-1.4.6)
# awk '{print $3}': Select the third item in the line, seperated by whitespace
# xargs ...: Run adb for each line piped in
adb devices -l | egrep '(device|emulator) usb' | awk '{print $3}' | xargs -t -I% -n1 -P5 \
adb -s % "$@"
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:id="@+id/enabled"
android:drawable="@drawable/ic_protection_enabled"
android:state_enabled="true" />
<item
android:id="@+id/disabled"
android:drawable="@drawable/ic_protection_disabled" />
</selector>
findViewById(R.id.icon).setEnabled(true);
<ImageView
android:id="@+id/icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/ic_protection" />
<animated-selector xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:id="@+id/enabled"
android:drawable="@drawable/ic_protection_enabled"
android:state_enabled="true" />
<item
android:id="@+id/disabled"
android:drawable="@drawable/ic_protection_disabled" />
<transition
<?xml version="1.0" encoding="utf-8"?>
<!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
<animated-vector
xmlns:android="http://schemas.android.com/apk/res/android"
android:drawable="@drawable/ic_protection_disabled">
<target android:name="strike_thru_path" android:animation="@animator/strike_thru_path_disabled_to_enabled" />
<target android:name="strike_thru_gap" android:animation="@animator/strike_thru_gap_disabled_to_enabled" />
<target android:name="icon" android:animation="@animator/icon_disabled_to_enabled" />
<?xml version="1.0" encoding="utf-8"?>
<!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
<animated-vector
xmlns:android="http://schemas.android.com/apk/res/android"
android:drawable="@drawable/ic_protection_enabled">
<target android:name="strike_thru_path" android:animation="@animator/strike_thru_path_enabled_to_disabled" />
<target android:name="strike_thru_gap" android:animation="@animator/strike_thru_gap_enabled_to_disabled" />
<target android:name="icon" android:animation="@animator/icon_enabled_to_disabled" />
<set xmlns:android="http://schemas.android.com/apk/res/android">
<objectAnimator
android:propertyName="pathData"
android:duration="500"
android:valueFrom="M 20 1.6 L 21.4 3 L 21.9 2.5 C 20.9 3.5 19.5 2 20.5 1.1 L 20 1.6 Z"
android:valueTo="M 20 1.6 L 21.4 3 L 5.2 19.2 C 4.2 20.2 2.8 18.8 3.8 17.8 L 20 1.6 Z"
android:valueType="pathType" />
<objectAnimator
android:propertyName="fillColor"
android:duration="500"