This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 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, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# On slow systems, checking the cached .zcompdump file to see if it must be | |
# regenerated adds a noticable delay to zsh startup. This little hack restricts | |
# it to once a day. It should be pasted into your own completion file. | |
# | |
# The globbing is a little complicated here: | |
# - '#q' is an explicit glob qualifier that makes globbing work within zsh's [[ ]] construct. | |
# - 'N' makes the glob pattern evaluate to nothing when it doesn't match (rather than throw a globbing error) | |
# - '.' matches "regular files" | |
# - 'mh+24' matches files (or directories or whatever) that are older than 24 hours. | |
autoload -Uz compinit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/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 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 3a8fe43e9e073f26e44f62ad072079acd8b78de3 Mon Sep 17 00:00:00 2001 | |
From: =?UTF-8?q?Felix=20Bu=CC=88nemann?= <buenemann@louis.info> | |
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 + |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 | |
""" | |
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 | |
http://www.apache.org/licenses/LICENSE-2.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From c45dfdd8d0c3de53b4f56610292a72ecad321362 Mon Sep 17 00:00:00 2001 | |
From: =?UTF-8?q?=E6=9D=8E=E9=80=9A=E6=B4=B2?= <carter.li@eoitek.com> | |
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 -- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 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. |
The Digilent JTag uses FT2232, but its configuration EEPROM contains secrete data needed to be recoginzed by Xilinx ISE/Vivado. The following method only works on linux (tested on Ubuntu16.04), but the patched FT2232 doggle also works on Windows. Since WSL1 does not provide USB device access, the following method will not work for WSL1.
DONT use FT_Prog on offical Digilent cable, as it can trash the firmware! The offical eeprom contains secrete data that cannot be handled correctly by FT_Prog.
Here are steps to create a Digilent-like Jtag that can be used in Xilinx ISE and Vivado
- Install softwares:
sudo apt-get install libftdi1 ftdi-eeprom
- Create a file "flash_digilent.conf" with the following content:
OlderNewer