Skip to content

Instantly share code, notes, and snippets.

View ThiagoAnunciacao's full-sized avatar

Thiago ThiagoAnunciacao

View GitHub Profile
@jjb
jjb / file.md
Last active July 11, 2024 15:27
Using Jemalloc 5 with Ruby.md

For years, people have been using jemalloc with ruby. There were various benchmarks and discussions. Legend had it that Jemalloc 5 didn't work as well as Jemalloc 3.

Then, one day, hope appeared on the horizon. @wjordan offered a config for Jemalloc 5.

Ubuntu/Debian

FROM ruby:3.1.2-bullseye
RUN apt-get update ; \
@sorny
sorny / x11_forwarding_macos_docker.md
Last active July 5, 2024 17:42
X11 forwarding with macOS and Docker

X11 forwarding on macOS and docker

A quick guide on how to setup X11 forwarding on macOS when using docker containers requiring a DISPLAY. Works on both Intel and M1 macs!

This guide was tested on:

  • macOS Catalina 10.15.4
  • docker desktop 2.2.0.5 (43884) - stable release
  • XQuartz 2.7.11 (xorg-server 1.18.4)
  • Macbook Pro (Intel)
@wshayes
wshayes / example.py
Created June 8, 2019 22:17
[FastAPI Websocket Example #2] #fastapi
# https://github.com/tiangolo/fastapi/issues/258#issuecomment-495975801
from typing import List
from fastapi import FastAPI
from starlette.responses import HTMLResponse
from starlette.websockets import WebSocket, WebSocketDisconnect
app = FastAPI()
@mfd
mfd / webfonts.md
Last active November 25, 2023 05:48
webfont convert

Make WEBFONTS (woff/woff2/eot)

Installation

Install Webfontools from Homebrew:

brew tap bramstein/webfonttools
brew update

brew install sfnt2woff-zopfli