Skip to content

Instantly share code, notes, and snippets.

@rougier
rougier / nano-minibuffer.el
Created March 25, 2022 09:54
Minibuffer frame for Nano Emacs
;; Nicolas .P Rougier emacs configuration - mini-frame configuration
;; ---------------------------------------------------------------------
(require 'vertico)
(require 'marginalia)
(require 'mini-frame)
(defun minibuffer-setup ()
;; This prevents the header line to spill over second line
(let ((inhibit-message t))

Frankie Bagnardi aka GreenJello has passed away on Sept 13, 2021 at age 27

Many of you in this channel know of him because he spent much of his time helping others, his death is a great blow to the community

He lost his battle with depression

Rest In Peace Frankie, we will never forget you.

If you are in a dark place, please reach out to chanops or the ones closest to you

@joepie91
joepie91 / no-your-cryptocurrency-cannot-work.md
Last active September 24, 2024 04:36
No, your cryptocurrency cannot work

No, your cryptocurrency cannot work

Whenever the topic of Bitcoin's energy usage comes up, there's always a flood of hastily-constructed comments by people claiming that their favourite cryptocurrency isn't like Bitcoin, that their favourite cryptocurrency is energy-efficient and scalable and whatnot.

They're wrong, and are quite possibly trying to scam you. Let's look at why.

What is a cryptocurrency anyway?

There are plenty of intricate and complex articles trying to convince you that cryptocurrencies are the future. They usually heavily use jargon and vague terms, make vague promises, and generally give you a sense that there must be something there, but you always come away from them more confused than you were before.

@ClickerMonkey
ClickerMonkey / types.ts
Last active August 8, 2024 00:25
Typescript Helper Types
// when T is any|unknown, Y is returned, otherwise N
type IsAnyUnknown<T, Y, N> = unknown extends T ? Y : N;
// when T is never, Y is returned, otherwise N
type IsNever<T, Y = true, N = false> = [T] extends [never] ? Y : N;
// when T is a tuple, Y is returned, otherwise N
// valid tuples = [string], [string, boolean],
// invalid tuples = [], string[], (string | number)[]

Streaming with SOX

  • FILE audio file I/O
  • -d default audio device I/O
  • -p pipe: standard I/O

The simplest sox command format

sox INPUT_FILE OUTPUT_FILE
@aaronNGi
aaronNGi / newscript.sh
Created April 28, 2020 20:38
Boilerplate for new POSIX shell scripts
#!/bin/sh
prog_name=${0##*/}
version=1.0
version_text="Boilerplate for new scripts v$version"
options="h o: q v V"
help_text="Usage: $prog_name [-o <text>] [-hqvV] [<file>]...
Boilerplate for new scripts
@mlocati
mlocati / check-go-pear.phar.sh
Created January 23, 2019 09:35
Check if a go-pear.phar file is an official one
#!/bin/sh
# This script checks if a go-pear.phar is the same as one of the
# ones released on https://github.com/pear/pearweb_phars
#
# MIT License
# Made by Michele Locati <[email protected]> on 2019-01-23
set -o errexit
set -o nounset
@hasandiwan
hasandiwan / GeoErrorControllerTest.java
Last active December 26, 2018 05:53
Geonotes Unit Tests
package hello;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get;
import java.util.List;
import org.junit.Assert;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
@samme
samme / phaser-scenes-summary.md
Last active August 2, 2023 16:26
Phaser 3 Scenes Summary

Scene control

Calls without a key argument

These affect the calling scene only.

Example:

this.scene.start()

#!/bin/bash
set -e
# Ubuntu Developer Script For pdf2htmlEx
# Created by Rajeev Kannav Sharma
# http://rajeevkannav.github.io/
#
#
# Downloads and configures the following:
#