Skip to content

Instantly share code, notes, and snippets.

@maestrow
maestrow / List all monospaced fonts.linq
Created February 3, 2023 21:36
List all monospaced fonts
<Query Kind="Program">
<Namespace>System.Drawing</Namespace>
<Namespace>System.Runtime.InteropServices</Namespace>
</Query>
// https://stackoverflow.com/questions/12417432/how-to-get-all-monospaced-fonts-in-windows
internal class NativeMethods
{
public const Int32 LF_FACESIZE = 32;
@maestrow
maestrow / gh-code-clone-command.js
Created September 13, 2022 02:27
Tempermonkey script for github: Adds clone command to Code clone menu
// ==UserScript==
// @name Custom Clone Command
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match https://github.com/*
// @icon https://www.google.com/s2/favicons?sz=64&domain=github.com
// @grant none
// ==/UserScript==
@maestrow
maestrow / post.md
Last active April 13, 2022 22:11
Note Taking Apps
@maestrow
maestrow / post.md
Last active December 15, 2021 15:04
Why gatsby look into root for its config.json?

EACCES: permission denied, open '/root/.config/gatsby/config.json'

When calling gatsby from PHP script which itself interpreted by apache2 web server I'm getting an error: Error: EACCES: permission denied, open '/root/.config/gatsby/config.json' You don't have access to this file..

Shell script that was called from PHP with output ('+' sign followed by shell command):

+ whoami
myuser
+ node_modules/.bin/gatsby clean
Error: EACCES: permission denied, open '/root/.config/gatsby/config.json'
@maestrow
maestrow / post.md
Last active December 17, 2021 01:30
CMS
@maestrow
maestrow / post.md
Last active May 11, 2021 17:22
Compiler Theory & Syntax Analysis

Guido van Rossum

Серия статей от основателя Python - Guido van Rossum по теме [PEG - Parsing Expression Grammars][guido-toc]. В серии есть [статья об устранении левой рекурсии][guido-left]. Примечательно, что Guido решил делать новый парсер на основе PEG (март 2020).

OMeta

https://en.wikipedia.org/wiki/OMeta

@maestrow
maestrow / post.md
Created April 27, 2021 09:17
VSCode: Integrated terminal very slow

VSCode: Integrated terminal very slow

Solution: Change the following settings:

"terminal.integrated.allowChords": false,
"terminal.integrated.drawBoldTextInBrightColors": false,
"terminal.integrated.experimentalLinkProvider": false,
"terminal.integrated.rendererType": "auto"
@maestrow
maestrow / post.md
Created March 17, 2021 13:12
Linux fundamental resources