Skip to content

Instantly share code, notes, and snippets.

View make-github-pseudonymous-again's full-sized avatar

Notas Hellout make-github-pseudonymous-again

  • Joined on Sep 24, 2012
View GitHub Profile
@joakim
joakim / nothing.js
Last active January 25, 2024 22:01
The concept of nothing in JavaScript (Crockford's idea of a better undefined)
nothing = new Proxy(Object.freeze(Object.create(null)), {
get(target, property) {
if (property === Symbol.toPrimitive) return () => undefined
return nothing
},
set() {
return nothing
}
})
@Eli-the-Bearded
Eli-the-Bearded / slowcat.c
Created August 21, 2020 04:11
cat, but slow, for old ASCII animations
/*
* Inspired by, but a nearly complete rewrite of:
* slowcat.c - slow down the display of a file
* copyright (c) 2001,2002,2007 dave w capella All Rights Reserved
* found here:
* https://grox.net/software/mine/slowcat/
* in August 2020.
*
* Original license (unchanged):
* * distributed under the terms of the GNU Public license
@taxilian
taxilian / README.md
Created November 9, 2019 22:13
Mongodb scripts for incremental backup

Introduction

I can't take credit for much of the work here -- I adapted it from this blog post: https://tech.willhaben.at/mongodb-incremental-backups-dff4c8f54d58

My main contribution was to make it a little easier to use with docker as well as numerous little cleanup tasks. I also made it gzip the oplog backups and added support for SSL connections

Note that I havne't yet tested the point in time restore script; it likely needs work, particularly to make things work with the gzipped oplog files

@g1eny0ung
g1eny0ung / 📊 Weekly development breakdown
Last active May 2, 2024 00:21
📊 Weekly development breakdown
Bash 3 hrs 24 mins ████████▏░░░░░░░░░░░░ 39.2%
Astro 2 hrs 54 mins ███████░░░░░░░░░░░░░░ 33.4%
YAML 1 hr 1 min ██▍░░░░░░░░░░░░░░░░░░ 11.7%
Markdown 43 mins █▊░░░░░░░░░░░░░░░░░░░ 8.3%
JSON 23 mins ▉░░░░░░░░░░░░░░░░░░░░ 4.5%
# Installation on Dell XPS 9570
# Connect to Internet
wifi-menu
# Sync clock
timedatectl set-ntp true
# Create three partitions:
@RichardBronosky
RichardBronosky / 0-TLDR.md
Last active March 23, 2024 15:09 — forked from datagrok/git-serve.md
How to easily launch a temporary one-off git server from any local repository, to enable a peer-to-peer git workflow.

User 1

remote_server=172.31.0.1
git daemon --verbose --export-all --base-path=.git --reuseaddr --strict-paths .git/ > /tmp/git-serve.log 2>&1 &
ssh -R 9418:localhost:9418 ec2-user@$remote_server
git clone git://localhost/ local-repo-name

Repo from workstation is cloned onto server.

User 2

@egmontkob
egmontkob / Hyperlinks_in_Terminal_Emulators.md
Last active April 30, 2024 17:02
Hyperlinks in Terminal Emulators

Aligning images

This is a guide for aligning images.

See the full Advanced Markdown doc for more tips and tricks

left alignment

@timvieira
timvieira / heap-sample.py
Created November 26, 2016 19:21
Fast sampling from an evolving distribution
import numpy as np
from numpy.random import uniform
def update(S, k, v):
"Update value position `k` in time O(log n)."
d = S.shape[0]
i = d//2 + k
S[i] = v
while i > 0:
@dmccombs
dmccombs / config.fish
Created April 28, 2016 00:59
A simple way to use the GNOME keyring for SSH key managment in fish shell
# Add this to the bottom of your config.fish file
# Set SSH to use Gnome keyring
set -gx SSH_AUTH_SOCK (gnome-keyring-daemon --start | grep "^SSH_AUTH_SOCK" | awk -F "=" '{print $2}')