Skip to content

Instantly share code, notes, and snippets.

@matusnovak
matusnovak / README.md
Last active March 29, 2024 00:28
GPG + Git SSH Authentication and Signing on Windows 10

GPG + Git SSH Authentication and Signing on Windows 10

Introduction

This simple Gist will explain how to settup your GPG key to work for SSH authentication (with Git) and Git commit signing on Windows 10. This may seem straightforward on Linux, but there are certain tweaks needed on Windows.

No Cygwin, no MinGW, no Git Bash or any other Linux emulated environment. This works in pure Windows 10.

Software needed

@OrionReed
OrionReed / DOM3D.js
Last active March 29, 2024 00:27
3D DOM viewer, copy-paste this into your console to visualise the DOM topographically.
// 3D Dom viewer, copy-paste this into your console to visualise the DOM as a stack of solid blocks.
// You can also minify and save it as a bookmarklet (https://www.freecodecamp.org/news/what-are-bookmarklets/)
(() => {
const SHOW_SIDES = false; // color sides of DOM nodes?
const COLOR_SURFACE = true; // color tops of DOM nodes?
const COLOR_RANDOM = false; // randomise color?
const COLOR_HUE = 190; // hue in HSL (https://hslpicker.com)
const MAX_ROTATION = 180; // set to 360 to rotate all the way round
const THICKNESS = 20; // thickness of layers
const DISTANCE = 10000; // ¯\\_(ツ)_/¯
@diego3g
diego3g / settings.json
Last active March 29, 2024 00:26
VSCode Settings (Updated)
{
"workbench.startupEditor": "newUntitledFile",
"editor.fontSize": 14,
"editor.lineHeight": 1.8,
"javascript.suggest.autoImports": true,
"javascript.updateImportsOnFileMove.enabled": "always",
"editor.rulers": [80, 120],
"extensions.ignoreRecommendations": true,
"typescript.tsserver.log": "off",
"files.associations": {
@ceving
ceving / Web Component for Copyright Years.md
Last active March 29, 2024 00:24
Web Component for Copyright Years
@yohhoy
yohhoy / yuvrgb.md
Last active March 29, 2024 00:19
RGB <=> YCbCr(YPbPr) color space conversion
Y  = a * R + b * G + c * B
Cb = (B - Y) / d
Cr = (R - Y) / e
BT.601 BT.709 BT.2020
a 0.299 0.2126 0.2627
b 0.587 0.7152 0.6780
@antlionguard
antlionguard / twitter-remove-retweets.js
Last active March 29, 2024 00:17
With this script, you can remove all retweets you are retweeted on Twitter.
const timer = ms => new Promise(res => setTimeout(res, ms));
// Unretweet normally
const unretweetTweet = async (tweet) => {
await tweet.querySelector('div[data-testid="unretweet"]').click();
await timer(250);
await document.querySelector('div[data-testid="unretweetConfirm"]').click();
console.log('****// Unretweeted Successfully //****')
}
@mirrornerror
mirrornerror / TSP_LP_scipy.ipynb
Last active March 29, 2024 00:16
TSP LP with scipy.optimize.linprog
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@ikbelkirasan
ikbelkirasan / writing-a-state-of-the-art-section.md
Created November 1, 2018 19:28
Writing the "Related Work" Section of a Paper/thesis

Writing the "Related Work" Section of a Paper/thesis

By: Chamin Morikawa (https://www.linkedin.com/pulse/writing-related-work-section-paperthesis-chamin-morikawa/)

For most students, writing about what they did on their own is not hard. But writing about others' work - which is what you have to do in the "State of the Art" or "Related Work" section - is quite hard for them. Here are a few guidelines to make this task a bit easier.

The Basics

Let's lay down our assumptions before continuing. I assume that you want to write a "Related Work" section for a research paper or a thesis that describes your approach to solve some problem. Let's also assume that there are other publications that attempt to solve the same problem, but the solutions in them are not perfect. Finally, let's assume that your approach has some difference when compared to those by others, and some improvement (faster, more accurate, easier to afford, etc.).