Skip to content

Instantly share code, notes, and snippets.

Avatar
😐
Trying to fix the world

Сухарик suhr

😐
Trying to fix the world
View GitHub Profile
View system_flakes.md
View gist:46340b73129f85ef42f4c5eb5795227f
{
"nodes": {
"nix": {
"inputs": {
"nixpkgs": "nixpkgs"
},
"locked": {
"lastModified": 1596472492,
"narHash": "sha256-tDghU8H3KU2LP6SY6HtugEBtEdQmPN2TfW8FgS/kCKs=",
"owner": "NixOS",
View gist:ddd5c66263e47dbddeb534ec0c665663
смежные(1, 2). смежные(2, 1).
смежные(1, 3). смежные(3, 1).
смежные(1, 4). смежные(4, 1).
смежные(1, 5). смежные(5, 1).
смежные(2, 3). смежные(3, 2).
смежные(2, 4). смежные(4, 2).
смежные(3, 4). смежные(4, 3).
смежные(4, 5). смежные(5, 4).
цвет(1, красный, а). цвет(1, красный, б).
View task.cue
{
PendingTask | EndedTask | WaitingTask | RecurringParrentTask | RecurringChildTask
...
}
Task :: {
status: Status
uuid: Uuid
entry: Date
description: string
View rosie.nix
with import <nixpkgs> {};
stdenv.mkDerivation rec {
pname = "rosie";
version = "1.2.1";
src = fetchgit {
url = "https://gitlab.com/rosie-pattern-language/rosie.git";
rev = "v${version}";
sha256 = "1fgp48q9xn8fc4zbpyc2issmmc6lrdsxpa93nk3xaj0qcj6kgz78";
View ws-boilerplate.ts
type Message =
{ kind: "request", request: string, fields: [string, string][] } |
{ kind: "response", response: string, fields: [string, string][] } |
{ kind: "event", event: string, fields: [string, string][] }
type Enum = { kind: "enum", enum: string, items: string[] }
type SpecItem = Message | Enum
function messageName(msg: Message): string {
switch(msg.kind) {
View chords.css
/* My design skills suck. But that doesn't mean I shouldn't try to make the site look better */
body > div {
margin: auto;
padding-left: 1em;
width: 58em;
/* Replace this with Arial if you need to */
/*font-family: 'Roboto' !important;*/
/* No adaptive font size also sucks */
font-size: 16px;
@suhr
suhr / monochord.md
Last active Jan 1, 2019
Monochord: implementing a musical tunings library
View monochord.md

First at all, falsehoods programmers believe about musical tuning:

  • C♯ and D♭ are the same notes
  • C𝄪 and D are the same notes
  • Semitone is 100 cents wide
  • There's only 12 notes in the octave
    • There's only 24 notes
    • Okay, 31 notes
    • Come on, 72 notes per octave is enough for everybody
    • You're kidding, right?
View vmjk.md

Virtual Midi Janko Keyboard

The good thing about language-related subreddits is you can always tell people there about your hello world project, and the good thing about medium sized subreddits is your post might even be noticed.

So let's talk about mine one.

What

View .XCompose
include "/usr/share/X11/locale/en_US.UTF-8/Compose"
# Punctuation
# знаки препинания, необходимые в русском, которых нет в en_US.UTF-8/Compose
<Multi_key> <period> <minus> : "…" U2026 # HORIZONTAL ELLIPSIS, многоточие
<Multi_key> <period> <space> : "…" U2026 # HORIZONTAL ELLIPSIS, многоточие
<Multi_key> <?> <!> : "⁈" U2048 # QUESTION EXCLAMATION, ?!
<Multi_key> <period> <colon> : "…" # ELLIPSIS
# №: набирается в русской раскладке без ухищрений,