Skip to content

Instantly share code, notes, and snippets.

View dawaltconley's full-sized avatar

Dylan Awalt-Conley dawaltconley

View GitHub Profile
@dawaltconley
dawaltconley / index.js
Last active June 13, 2023 19:55
Generate markdown documentation from CloudFormation templates
/**
* @typedef {{
* [Prop: string]: any;
* Default?: string | number;
* Description?: string;
* }} Parameter
*/
/**
* @typedef {{
@dawaltconley
dawaltconley / README.md
Last active October 14, 2022 05:25
ABR Background Videos

ABR Background Videos

An ffmpeg command that produces abr video assets suitable for silent web background video. I'm using shaka-player to stream the resulting files.

I went through several iterations of this, and other variations could work as well. I believe this produces all the assets needed for cross-browser compatibility. Safari needs mp4, and iOS Safari (at least the version my old MacBook can simulate) will only play HLS, even with shaka-player.

@dawaltconley
dawaltconley / README.md
Last active November 16, 2023 19:52
Enabling hibernation with full disk encryption on Pop!_OS 21.04.

Enabling hibernation with full disk encryption on Pop!_OS 21.04.

I am recording the steps I took here to enable hibernation on a default Pop!_OS installation with full-disk encryption. I have written my commands as a single executable script in order to better understand how they all relate, but they probably should not be executed this way. Use this guide with caution and only if you understand what each command does.

I did all of this on Pop!_OS version 21.04, but swapfile hibernation is still working for me as of 22.04. I expect that the following steps will work for that as well, but I haven't tested it.

Using a swapfile

This is the simplest method if you used the default Pop installation, since it does not involve resizing any encrypted partitions.

@dawaltconley
dawaltconley / parallel.js
Created June 18, 2021 21:14
A simple module for executing some maximum number of async functions in parallel.
module.exports = async (tasks, n) => {
const results = new Array(tasks.length);
const executing = [];
let index = 0;
while (index < tasks.length || executing.length) {
if (index < tasks.length && executing.length < n) {
let task = tasks[index];
let taskIndex = index;
task = task().then(r => {
const i = executing.indexOf(task);
@dawaltconley
dawaltconley / index.html
Last active July 7, 2018 01:33
Parallax Gap Fix
<select id="fix-options">
<option value="null">Bug</option>
<option value="fix-1">Fix 1</option>
<option value="fix-2">Fix 2</option>
<option value="fix-3">Fix 3</option>
<option value="fix-4">Fix 4</option>
<option value="fix-5">Fix 5</option>
</select>
<div class="parallax-page">
<div class="parallax-group screen-height">