Skip to content

Instantly share code, notes, and snippets.

@joshbuchea
joshbuchea / semantic-commit-messages.md
Last active April 23, 2024 17:36
Semantic Commit Messages

Semantic Commit Messages

See how a minor change to your commit message style can make you a better programmer.

Format: <type>(<scope>): <subject>

<scope> is optional

Example

@SwampDragons
SwampDragons / README.md
Created June 7, 2022 16:49
Using a Nook Simple Touch in 2022

Using an old Barnes and Noble Nook Device

I got an ancient nook "simple touch" for free on a neighborhood Facebook group yesterday. Figured I could see if I at least like the form factor before getting myself a newer one.

Step 1: Charge it

When I got it, the battery was completely dead. I plugged it in to charge (thankfully a micro-USB charger). After about 20 minutes, it was ready to work on.

Step 2: Hardware Reset

@jboner
jboner / latency.txt
Last active April 23, 2024 17:34
Latency Numbers Every Programmer Should Know
Latency Comparison Numbers (~2012)
----------------------------------
L1 cache reference 0.5 ns
Branch mispredict 5 ns
L2 cache reference 7 ns 14x L1 cache
Mutex lock/unlock 25 ns
Main memory reference 100 ns 20x L2 cache, 200x L1 cache
Compress 1K bytes with Zippy 3,000 ns 3 us
Send 1K bytes over 1 Gbps network 10,000 ns 10 us
Read 4K randomly from SSD* 150,000 ns 150 us ~1GB/sec SSD
@catalinmiron
catalinmiron / README.md
Created April 16, 2024 20:36
Expo app.json Apple Privacy Manifest

About

The privacy details that you may need to add for Apple Privacy Manifest.

This config plugin it's already available from expo >=50.0.17 (Part of this PR by aleqsio)

Tip

Read more about Privacy Manifest File from Apple docs

@paulmillr
paulmillr / active.md
Last active April 23, 2024 17:32
Most active GitHub users (by contributions). http://twitter.com/paulmillr

Most active GitHub users (git.io/top)

The count of contributions (summary of Pull Requests, opened issues and commits) to public repos at GitHub.com from Wed, 21 Sep 2022 till Thu, 21 Sep 2023.

Only first 1000 GitHub users according to the count of followers are taken. This is because of limitations of GitHub search. Sorting algo in pseudocode:

githubUsers
 .filter(user =&gt; user.followers &gt; 1000)
@thekendog
thekendog / gist:69b28bd0bda0b949a909602173c2e95a
Last active April 23, 2024 17:32
Set Kadence Blocks colors to those from Blocksy theme.
/**
* Set the colors from Blocksy to match those of Kadence blocks
*/
add_filter('kadence_blocks_pattern_global_colors', function($kadence_colors) {
if ( !function_exists('blocksy_get_theme_mod') ) {
return $kadence_colors;
}
$colorPalette = blocksy_get_theme_mod('colorPalette');
@escopecz
escopecz / form.html
Last active April 23, 2024 17:29
An example of how to send a form submission to a Mautic form with jQuery
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Mautic Form Test</title>
<script src="https://code.jquery.com/jquery-3.3.1.min.js"></script>
<script src="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script>
@guwidoe
guwidoe / VBA-Keywords.md
Last active April 23, 2024 17:29
Exhaustive list of VBA Keywords, including categories reserved and non-reserved

Exhaustive lists of VBA Keywords and Symbols

Copyright (c) 2023 Guido Witt-Dörring (MIT License)

This document attempts to provide various exhaustive lists of VBA keywords and symbols using various categorizations. This is useful because the official documentation is convoluted and incomplete and it is very difficult to derive such lists from official sources.

If you find missing keywords or mistakes in any of the lists or have any suggestions, please don't hesitate to leave a comment below.

Table of Contents

  1. Keywords
@firelightning13
firelightning13 / [GUIDE] GPU Passthrough for Laptop with Fedora.md
Last active April 23, 2024 17:27
[GUIDE] GPU Passthrough for Laptop with Fedora

Abstract

This is a full guide for people who wanted to setup Windows 10/11 VM with QEMU/KVM hypervisor for laptops that configured with hybrid graphics card like Intel/AMD + NVIDIA. This process will take about 1 to 2 hours, depending on your system's performance.

There is another comprehensive guide you can follow here (shoutout to asus-linux team). It is more up-to-date than mine. I'll probably incorporate those information to my guide, but you are welcome to use this one as a reference!

Before we proceed:

  • This guide is exclusively for Fedora because this distro is quite different to set up than other distro such as Arch. I would say Arch is easier to setup than Fedora, but sometimes your prefer Fedora than Arch in terms of its usage & features.
  • This tutorial mostly focus on laptops with NVIDIA Optimus MUXed configuration when dGPU (dedicated GPU) can connect directly to HDMI/DP output. If in doubt, sea
/**
* This Google Sheets script keeps data in the specified column sorted any time
* the data changes.
*
* After much research, there wasn't an easy way to automatically keep a column
* sorted in Google Sheets, and creating a second sheet to act as a "view" to
* my primary one in order to achieve that was not an option. Instead, I
* created a script that watches for when a cell is edited and triggers
* an auto sort.
*