Skip to content

Instantly share code, notes, and snippets.

View rpavlik's full-sized avatar

Rylie Pavlik rpavlik

View GitHub Profile
@rpavlik
rpavlik / code.py
Last active July 31, 2021 21:05
MagTag CovidActNow
# Adapted from SpaceX Launch Display example
# SPDX-FileCopyrightText: Anne Barela November 2020, for Adafruit Industries LLC
# SPDX-FileCopyrightText: 2020-2021, Ryan Pavlik
# SPDX-License-Identifier: MIT
import time
import terminalio
from adafruit_magtag.magtag import MagTag
from secrets import secrets
@rpavlik
rpavlik / cs-unc-tr-to-ris-zotero.sh
Last active July 14, 2021 17:48
Get the UNC CS dept tech report list and convert for zotero import
#!/usr/bin/env bash
# Copyright 2021, Collabora, Ltd.
# SPDX-License-Identifier: MIT
#
# needs bibutils and sed and wget on debian.
# Import the resulting .ris file into zotero and enjoy!
# References:
# https://en.wikipedia.org/wiki/EndNote#Tags_and_fields
# https://en.wikipedia.org/wiki/RIS_(file_format)#Tags
Executing tasks: [:app:assembleDebug] in project /home/ryan/AndroidStudioProjects/PrefabProblem
> Task :app:preBuild UP-TO-DATE
> Task :app:preDebugBuild UP-TO-DATE
> Task :app:compileDebugAidl NO-SOURCE
> Task :app:compileDebugRenderscript NO-SOURCE
> Task :app:dataBindingMergeDependencyArtifactsDebug
> Task :app:dataBindingMergeGenClassesDebug
> Task :app:generateDebugResValues
> Task :app:generateDebugResources
@rpavlik
rpavlik / WindowsRX580.md
Created November 19, 2020 16:43
Ryan's available vulkan extensions
  • Instance Extensions: count = 11
    • VK_EXT_debug_report : extension revision 9
    • VK_EXT_debug_utils : extension revision 2
    • VK_EXT_swapchain_colorspace : extension revision 4
    • VK_KHR_device_group_creation : extension revision 1
    • VK_KHR_external_fence_capabilities : extension revision 1
    • VK_KHR_external_memory_capabilities : extension revision 1
    • VK_KHR_external_semaphore_capabilities : extension revision 1
    • VK_KHR_get_physical_device_properties2 : extension revision 2
  • VK_KHR_get_surface_capabilities2 : extension revision 1
@rpavlik
rpavlik / PushBulletBookmarklet.js
Last active October 30, 2020 16:41 — forked from Ashish879/PushBulletBookmarklet.js
PushBullet Bookmarklet
(function() {
var API_KEY = "YOUR_API_KEY_GOES_HERE";
// code for IE7+, Firefox, Chrome, Opera, Safari - forget IE6
var xmlhttp = new XMLHttpRequest();
xmlhttp.open("POST", "https://api.pushbullet.com/v2/pushes", true);
xmlhttp.setRequestHeader('Content-Type', 'application/json');
xmlhttp.setRequestHeader('Authorization', "Bearer " + API_KEY);
/// @todo needs oauth2 update? ugh.
@rpavlik
rpavlik / win-terminal-git-bash.json
Last active August 7, 2020 15:35
Git Bash option for recent Windows Terminal
[
{},
{
"guid": "{0ccdb49b-c762-4bd6-99f4-9f85e25ffea1}",
"closeOnExit": true,
"commandline": "\"%PROGRAMFILES%\\git\\bin\\bash.exe\" -i -l",
"icon": "%PROGRAMFILES%\\git\\mingw64\\share\\git\\git-for-windows.ico",
"name": "Git Bash",
"startingDirectory": "W:\\src"
}
@rpavlik
rpavlik / 3d-printing-links.md
Last active April 3, 2020 14:32
Ryan's Trusted 3D Printing People
@rpavlik
rpavlik / PRs merged into my master branch.md
Last active March 25, 2020 15:31
vcglib custom master description

Upstream of vcglib is not as quick on reviews, so I've merged some things that look pretty safe (or important) into master on my fork: https://github.com/rpavlik/vcglib

@rpavlik
rpavlik / out_camera_data.xml
Created November 8, 2019 15:20
Calibration file for a wide-angle ELP board-level camera
<?xml version="1.0"?>
<opencv_storage>
<calibration_time>"Thu 07 Nov 2019 05:21:22 PM CST"</calibration_time>
<nr_of_frames>25</nr_of_frames>
<image_width>1600</image_width>
<image_height>1200</image_height>
<board_width>9</board_width>
<board_height>6</board_height>
<square_size>1.6210000030696392e-03</square_size>
<fix_aspect_ratio>1.</fix_aspect_ratio>
@rpavlik
rpavlik / filter.sh
Last active October 11, 2019 05:15
Extreme git filter-branch: keep only one or a few files
# Based on <http://git.661346.n2.nabble.com/Remove-all-files-except-a-few-files-using-filter-branch-td7567155.html>
# for most of it (the index filter part) and on this SO answer for how to get rid of the many meaningless commits now:
# <http://stackoverflow.com/a/5326065/265522>
git filter-branch --index-filter "git rm --cached -qr -- . && git reset -q $GIT_COMMIT -- THEFILEYOUWANTTOKEEP" # --prune-empty
git filter-branch --commit-filter 'git_commit_non_empty_tree "$@"'