Skip to content

Instantly share code, notes, and snippets.

View kateliev's full-sized avatar
🧲
Working, working, working...

Vassil Kateliev kateliev

🧲
Working, working, working...
View GitHub Profile
@anthrotype
anthrotype / glyf2svg.py
Created November 12, 2020 19:14
Convert TrueType glyph outline to SVG
#!/usr/bin/env python3
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
import collections
import io
import itertools
import logging
import os
import sys
from pathlib import Path
from pprint import pprint
from typing import Dict, List, Tuple
@transitive-bullshit
transitive-bullshit / embed-animated-svg.html
Created March 7, 2018 22:38
Embed animated svg in GitHub-flavored Markdown Example
<p align="center">
<img width="600" src="https://cdn.rawgit.com/transitive-bullshit/create-react-library/master/media/demo.svg">
</p>
@henfiber
henfiber / KB-Buying-guide-EU.md
Last active November 9, 2024 13:35
Buying keyboards and keyboard components from EU

Europe

  • SkinFlint : Price comparison site which has some nice filtering options per switch type etc. Searches for offers in UK, Germany, Poland and Austria
  • mykeyboard.eu : Keyboards, keycaps and accessories. Based in Belgium.
  • candykeys.com : European Store selling Vortex, Leopold, KBP, Anne Pro keyboards, keycap sets and components (ISO + ANSI). Based in Germany, ships to EU.
  • falba.tech : custom wooden bamboo cases, and some acrylic and carbon ones. Switch packs (65 browns at 48EUR). Other parts for the GH60, Atreus, ErgoDox. Also Microcontrollers, diodes, leds etc.
  • 42keebs.eu - Mostly PCBs, tools and accessories. Located in Czech Republic.
  • KEYGEM : Switches, Keycaps, lubes, cables, DIY kits and deskmats. Based in Germany, ships to the EU and worldwide.
  • [Eloquent Clicks - Custom Mechanical Keyboard Store](https://www.eloquen
@maksymx
maksymx / PASCAL.sublime-build
Last active August 8, 2023 14:21
Sublime Text build system for Pascal project
{
"cmd": ["fpcbuild.bat", "$file"], "quiet": true
}
@staypufd
staypufd / .lisp
Created February 5, 2016 04:10
Example of using SPLIT-SEQUENCE from cl-utilities package for Common Lisp
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; 1. Example of using quicklisp to laod in
;;; cl-utilities and use one function
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; Load in the cl-utilities package
(ql:quickload "cl-utilities")
;;; Tell the cl-user namespace to use the cl-utilities package
@w495
w495 / sliding_window.py
Last active January 20, 2021 18:19
Sliding window as deque. Yet another implementation of sliding (rolling) window iterator in Python. This is based on answers of http://stackoverflow.com/questions/6822725/rolling-or-sliding-window-iterator-in-python. It is improved with "overlapping" and two window types: soft and strict.
# -*- coding: utf8 -*-
from __future__ import absolute_import, division, print_function, unicode_literals
import collections
import types
import itertools
class SlidingWindow(collections.deque):
@cchamberlain
cchamberlain / rdiff.ps1
Last active September 30, 2024 14:38
Recursively diffs 2 directories (files and contents) using MD5 hashes - Includes validation for paths and optional summary export. Requires PowerShell 3.0 or later.
#########################################################################
### USAGE: rdiff path/to/left,path/to/right [-s path/to/summary/dir] ###
### ADD LOCATION OF THIS SCRIPT TO PATH ###
#########################################################################
[CmdletBinding()]
param (
[parameter(HelpMessage="Stores the execution working directory.")]
[string]$ExecutionDirectory=$PWD,
[parameter(Position=0,HelpMessage="Compare two directories recursively for differences.")]
@wynnzen
wynnzen / repl_shortcut
Last active September 20, 2023 09:20
sublime repl shortcut setting
[
{"keys":["f5"],
"caption": "SublimeREPL: Python - RUN current file",
"command": "run_existing_window_command",
"args":
{
"id": "repl_python_run",
"file": "config/Python/Main.sublime-menu"
}},
{"keys":["f4"],
@sayedihashimi
sayedihashimi / resolve-fullpath.ps1
Created August 5, 2014 09:11
PowerShell how to convert a relative path to a full path
# based off of http://mnaoumov.wordpress.com/2013/08/21/powershell-resolve-path-safe/
function Resolve-FullPath{
[cmdletbinding()]
param
(
[Parameter(
Mandatory=$true,
Position=0,
ValueFromPipeline=$true)]
[string] $path