Skip to content

Instantly share code, notes, and snippets.

View Calinou's full-sized avatar
🦄
______ is best pony.​

Hugo Locurcio Calinou

🦄
______ is best pony.​
View GitHub Profile
@Calinou
Calinou / build_osx.sh
Last active March 7, 2017 20:25
Compile Godot for macOS easily
#!/bin/sh -x
# This script must be run from a macOS system with
# Xcode installed.
# Place this script at the root of your Godot Git clone.
# CC0 1.0 Universal
# Number of CPU threads to use for compilation (no "nproc" on macOS...)
nproc=4
@Calinou
Calinou / .bintray.json
Last active July 6, 2017 12:25
Godot build Bintray deployment (Travis, macOS)
{
"package": {
"name": "editor",
"repo": "godot",
"subject": "calinou"
},
"version": {
"name": "${VERSION}",
"desc": "Autogenerated Godot Engine Editor build",
"released": "${DATE}",
@Calinou
Calinou / .rtorrent.rc
Created September 3, 2017 15:12
rTorrent configuration file
scgi_port = 127.0.0.1:5000
dht.mode.set = on
protocol.pex.set = yes
trackers.use_udp.set = yes
throttle.max_uploads.set = 100
throttle.max_uploads.global.set = 250
throttle.min_peers.normal.set = 20
throttle.max_peers.normal.set = 60
@Calinou
Calinou / keybase.md
Created October 15, 2017 20:06
Keybase proof

Keybase proof

I hereby claim:

  • I am calinou on github.
  • I am calinou (https://keybase.io/calinou) on keybase.
  • I have a public key ASBWFkyj4HxyO42KjpXXu-CEFDsgWgpMXTIBW6EvTxGTcwo

To claim this, I am signing this object:

@Calinou
Calinou / render.bat
Created October 15, 2017 23:04
Render my avatar into PNGs of several sizes
@ECHO OFF
mkdir "dist\"
for /L %%a in (24, 24, 480) do (
convert -scale %%a "src\avatar-foreground.png" "%TMP%\avatar-foreground-%%a.png"
"%PROGRAMFILES%\Inkscape\inkscape.exe" "src\avatar-background.svg" --export-width %%a --export-height %%a --export-png "%TMP%\avatar-background-%%a.png"
composite "%TMP%\avatar-foreground-%%a.png" "%TMP%\avatar-background-%%a.png" "%TMP%\avatar-%%a.png"
oxipng -o6 "%TMP%\avatar-%%a.png"
copy "%TMP%\avatar-%%a.png" "dist\avatar-%%a.png"
@Calinou
Calinou / brotli_static.sh
Created April 30, 2018 17:54
Compress static assets to Brotli (usable by nginx's brotli_static module)
#!/bin/bash
set -euo pipefail
IFS=$'\n\t'
DIR=${1:-}
if [[ "$DIR" == "" ]]; then
echo "Usage: $(basename $0) <path>"
exit 1
@Calinou
Calinou / product.json
Created May 10, 2018 19:47
Code - OSS extension gallery
{
...
"extensionsGallery": {
"serviceUrl": "https://marketplace.visualstudio.com/_apis/public/gallery",
"cacheUrl": "https://vscode.blob.core.windows.net/gallery/index",
"itemUrl": "https://marketplace.visualstudio.com/items"
}
}
@Calinou
Calinou / render_intro_outro.sh
Created June 4, 2018 21:55
Render intro/outro images for use with the Blender Video Sequence Editor
#!/bin/bash
#
# Renders video intro/outro images; targeted at Blender usage.
# Usage: ./render.sh
#
# Copyright © 2018 Hugo Locurcio
# Licensed under CC0 1.0 Universal: https://creativecommons.org/publicdomain/zero/1.0/
set -euo pipefail
IFS=$'\n\t'
@Calinou
Calinou / build_android.bat
Last active September 21, 2018 04:36
Compile Godot for Android easily (on Windows)
:: This script must be run from a Windows machine with
:: Android SDK and NDK installed.
:: NOTE: You need Pywin32 to be installed to use multi-threaded compilation.
:: You may need to set "threads" to 1 for the first build, even if you have it installed.
:: Place this script at the root of your Godot Git clone.
:: CC0 1.0 Universal
set threads=%NUMBER_OF_PROCESSORS%
@Calinou
Calinou / modern-font-stack.css
Last active October 2, 2018 20:07
Userstyle to enforce a modern font stack on all websites
/* ==UserStyle==
@name Modern Font Stack
@namespace github.com/openstyles/stylus
@version 1.0.0
@license MIT
@description Replaces Segoe UI, Arial and Helvetica Neue with IBM Plex Sans on all websites
@author Calinou
==/UserStyle== */
@-moz-document regexp(".*") {