Skip to content

Instantly share code, notes, and snippets.

ksco / chai.json
Last active May 6, 2022
View chai.json
"卧": "臣卜",
"项": "工页",
"功": "工力",
"攻": "工攵",
"荆": "茾刂",
"邪": "牙阝",
"雅": "牙隹",
"期": "其月",
"欺": "其欠",
dzcpy / 超大字符集字体.md
Last active Sep 17, 2022
View 超大字符集字体.md




  • 中易宋体(Windows 10 version 1809):部分支持CJK-E
13a81e63aae736ca2254492dd111d3ace4e9dbe9 *simsun.ttc
91a6e66e7c1139a27b6caa313dc451af36e4e5ed *simsunb.ttf
shane-axiom / nginx_google_analytics
Last active Aug 12, 2022
google analytics in nginx
View nginx_google_analytics
# send logs for all traffic (including non-html) to google analytics
# in server block:
# set $google_analytics_id "UA-THECORRECT-ID";
# include /srv/nginx/google_analytics;
# in location blocks:
# post_action @ga;
# notes: post_action has been referred to by nginx devs as a "dirty hack" and this approach may stop working one day.
CarterLi / add_proxy_ssl_alpn_directive.diff
Created Jun 15, 2018
Backport nginx patches from google nginx
View add_proxy_ssl_alpn_directive.diff
From c45dfdd8d0c3de53b4f56610292a72ecad321362 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9D=8E=E9=80=9A=E6=B4=B2?= <>
Date: Fri, 15 Jun 2018 14:58:33 +0800
Subject: [PATCH] add "proxy_ssl_alpn" directive
src/event/ngx_event_openssl.c | 22 ++++++++++++++++++
src/event/ngx_event_openssl.h | 2 ++
src/http/modules/ngx_http_proxy_module.c | 29 ++++++++++++++++++++++++
src/http/modules/ngx_http_ssl_module.c | 2 --
Mygod /
Last active Aug 28, 2022
Export your Windows Bluetooth LE keys into Linux!
Copyright 2021 Mygod
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
View nginx-1.9.15-spdy.patch
From 3a8fe43e9e073f26e44f62ad072079acd8b78de3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Felix=20Bu=CC=88nemann?= <>
Date: Mon, 30 May 2016 00:00:29 +0200
Subject: [PATCH] Add SPDY support back to Nginx with HTTP/2
Ported to 1.9.15 from 1.9.7 patch by Jiale Zhi from CloudFlare with
additional fixes to re-enable deprecated spdy directives and fix
compilation with http_v2 module enabled and spdy disabled.
auto/modules | 31 +
ymollard / clean_git_repository.bash
Created Feb 4, 2016
Clean a git repository by deleting history and data of old deleted files
View clean_git_repository.bash
# This script, executed at the root of a git repository, deletes traces of every old file in this repository, index + blob on all branches
# It can take 10-30 minutes to run and will print regular warning stating than some references are unchanged
# time ./clear_git_repositor.bash >cleaning.log
# We need several passes to clean files renamed multiple times (git log --find-renames prevents its deletion for each renaming)
# MAXIMUM_PASSES should be more than the maximum number of renamings/movings for any file, if not then we might keep some traces of former files
MAXIMUM_PASSES=10 # Maximum number of passes
aras-p / preprocessor_fun.h
Last active Sep 29, 2022
Things to commit just before leaving your job
View preprocessor_fun.h
// Just before switching jobs:
// Add one of these.
// Preferably into the same commit where you do a large merge.
// This started as a tweet with a joke of "C++ pro-tip: #define private public",
// and then it quickly escalated into more and more evil suggestions.
// I've tried to capture interesting suggestions here.
// Contributors: @r2d2rigo, @joeldevahl, @msinilo, @_Humus_,
// @YuriyODonnell, @rygorous, @cmuratori, @mike_acton, @grumpygiant,