Skip to content

Instantly share code, notes, and snippets.

View DerekNonGeneric's full-sized avatar

Derek Lewis DerekNonGeneric

View GitHub Profile
@antfu
antfu / doc-table.md
Last active October 14, 2023 20:09
Doc Table in Markdown

Example

Name

Description


@tueda
tueda / FootnoteExample.ipynb
Last active May 23, 2024 14:27
Jupyter Notebook Footnote example. This also works with Google Colaboratory.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
// node [--trace-gc] local-storage-exmaple.cjs
// creates a server
// will drop /favicon.ico connections poorly without properly closing them
// `cleanupContext` AsyncLocalStorage + `cleanup` FinalizationRegistry will clean up
// will track the http request URL for errors in httpContext
// will show up in error generated for bad permissions
// will grant permissions in permissionsContext based upon query params / search params
// need ?fs=true to make / respond with a 200
//
// goto /?fs=true in browser to see it work
@wiegertschouten
wiegertschouten / grid.scss
Created October 1, 2020 18:38
A very simple grid system built with SASS and CSS grid
$columns: 12;
$gap: 30px;
$breakpoints: (
xs: 480px,
sm: 768px,
md: 960px,
lg: 1170px,
xl: 1280px
);
@raghav4
raghav4 / Ansicolor.md
Created February 8, 2020 07:17
Color codes for console using Ansi
@seanh
seanh / README.md
Last active November 25, 2023 07:05
Breadcrumbs for GitHub Pages / Jekyll. Pure Liquid (no Jekyll plugin). https://seanh.github.io/posts/2020/01/01/jekyll-breadcrumbs/

Jekyll Breadcrumbs

This is a Jekyll template include that renders navigation breadcrumbs for a page or post. The breadcrumbs include the page or post's collection, categories, date and title. They look something like this:

Home > Posts > 2019 > Dec > 23 > My Blog Post

Installation

#!/usr/bin/python3
# Copyright 2019 Google LLC.
# SPDX-License-Identifier: Apache-2.0
# Sends an AMP email from a Gmail account.
import smtplib
from email import encoders
from email.mime.text import MIMEText
@oseme-techguy
oseme-techguy / Correct_GnuPG_Permission.sh
Last active June 9, 2024 07:46
This fixes the " gpg: WARNING: unsafe permissions on homedir '/home/path/to/user/.gnupg' " error while using Gnupg .
#!/usr/bin/env bash
# To fix the " gpg: WARNING: unsafe permissions on homedir '/home/path/to/user/.gnupg' " error
# Make sure that the .gnupg directory and its contents is accessibile by your user.
chown -R $(whoami) ~/.gnupg/
# Also correct the permissions and access rights on the directory
chmod 600 ~/.gnupg/*
chmod 700 ~/.gnupg
@rubys
rubys / html.diff
Created June 28, 2018 19:42
Instrumenting tools/doc/html.js for performance analysis
diff --git a/tools/doc/html.js b/tools/doc/html.js
index 974eab769c..b4153c4eee 100644
--- a/tools/doc/html.js
+++ b/tools/doc/html.js
@@ -53,6 +53,8 @@ function navClasses() {
}
}
+let start = new Date().getTime();
+