Skip to content

Instantly share code, notes, and snippets.

voluntas / sysctl.conf
Created Oct 14, 2017 — forked from techgaun/sysctl.conf
Sysctl configuration for high performance
View sysctl.conf
# Increase size of file handles and inode cache
fs.file-max = 2097152
# Do less swapping
vm.swappiness = 10
vm.dirty_ratio = 60
vm.dirty_background_ratio = 2
View Remove Sophos from Mac without tamper protection
cd /Library/Preferences
sudo rm com.sophos.sav.plist

cd /Library/Application\ Support/Sophos/cloud/
sudo ./InstallationDeployer —force_remove
peterjaap / server.blacklist
Last active Apr 1, 2020
Bad bot blacklist nginx config file (used on Hypernodes for Magento - place in /data/web/nginx/server.blacklist)
View server.blacklist
# Main list
if ($http_user_agent ~* (360Spider||Abonti|AcoonBot|Acunetix|adbeat_bot||adidxbot|ADmantX|AhrefsBot|AngloINFO|Antelope|Applebot|BaiduSpider|BeetleBot|billigerbot|binlar|bitlybot|BlackWidow|BLP_bbot|BoardReader|Bolt\ 0|BOT\ for\ JCE|Bot\ mailto\:craftbot@yahoo\.com|casper|CazoodleBot|CCBot|checkprivacy|ChinaClaw|chromeframe|Clerkbot|Cliqzbot|clshttp|CommonCrawler|comodo|CPython|crawler4j|Crawlera|CRAZYWEBCRAWLER|Curious|Curl|Custo|CWS_proxy|Default\ Browser\ 0|diavol|DigExt|Digincore|DIIbot|DISCo|discobot|DoCoMo|DotBot|Download\ Demon|DTS.Agent|EasouSpider|eCatch|ecxi|EirGrabber|Elmer|EmailCollector|EmailSiphon|EmailWolf|Exabot|ExaleadCloudView|ExpertSearch|ExpertSearchSpider|Express\ WebPictures|extract|ExtractorPro|EyeNetIE|Ezooms|F2S|FastSeek|feedfinder|FeedlyBot|FHscan|finbot|Flamingo_SearchEngine|FlappyBot|FlashGet|flicky|Flipboard|g00g1e|genieo|Genieo|GetRight|GetWeb\!|GigablastOpenSource|Go\-Ahead\-Got\-It|Go\!Zilla|GozaikBot|grab|GrabNet|Grafula|GrapeshotCrawler|GT\:\:
nnja / gist:9136152c163091614e70defcf3753d06
Created May 26, 2016
How to access the raw markdown source for a github wiki page
View gist:9136152c163091614e70defcf3753d06
anzuwork / !
Last active Jan 24, 2017
How to extract images on starlight stage.
View !


Since the App has changed the DB system.

Will work if a version earlier than 10012760.



jemekite / badbot.conf
Created Jul 25, 2015
NginX badbot blocker conf
View badbot.conf
if ($http_user_agent ~ "WebCrawlerJohn|Sphere|OptimizationCrawler|Apache-HttpClient|LinkpadBot||WeCrawlForThePeace|Xenu|SemanticScholarBot|Domain Re-Animator Bot|proximic|Sosospider|Sogou|Jorgee|ZumBot|MJ12bot|spbot|rojerbot|Exabot|dotbot|gigabot|AhrefsBot|accelobot|searchmetrics|awcheckBot|CompSpyBot|EasouSpider|purebot|Ezooms|SurveyBot|sitebot|dotnetdotcom|dotbot|SolomonoBot|ZmEu|lipperhey|WBSearchBot|Snoopy|AhrefsBot|DinoPing||discoverybot||360Spider|80legs|YamanaLab-Robot||Aboundex|Sleuth|NCBot|JikeSpider|Curious||SemrushBot|Dow Jones Searchbot|SISTRIX||magpie-crawler|YoudaoBot|TurnitinBot|aiHitBot|PeoplePal|EzineArticlesLinkScanner|ProCogSEOBot|ScreenerBot|PagesInventory|SeznamBot|libwww-perl|Lynx|Nutch|Java|SEOstats|Python-urllib|python-requests|HTTP_Request|HTTP_Request2|Zend_Http_Client|Jakarta Commons-HttpClient|The Incutio XML-RPC PHP Library|YisouSpider|SEOENGWorldBot|Netseer|Riddler|CLIPish|proximic|Mail.R
jackreichert / getKeyVals
Last active Mar 19, 2020
This is a swift extension for NSURL so you can parse the query string and get back a dictionary of the variables.
View getKeyVals
extension NSURL {
func getKeyVals() -> Dictionary<String, String>? {
var results = [String:String]()
var keyValues = self.query?.componentsSeparatedByString("&")
if keyValues?.count > 0 {
for pair in keyValues! {
let kv = pair.componentsSeparatedByString("=")
if kv.count > 1 {
results.updateValue(kv[1], forKey: kv[0])
sawapi / AppDelegate.swift
Last active Oct 5, 2020
[Swift] Push Notification
View AppDelegate.swift
// AppDelegate.swift
// pushtest
// Created by sawapi on 2014/06/08.
// Copyright (c) 2014年 sawapi. All rights reserved.
// iOS8用
import UIKit
tsiege / The Technical Interview Cheat
Last active Jan 28, 2023
This is my technical interview cheat sheet. Feel free to fork it or do whatever you want with it. PLEASE let me know if there are any errors or if anything crucial is missing. I will add more links soon.
View The Technical Interview Cheat


I have moved this over to the Tech Interview Cheat Sheet Repo and has been expanded and even has code challenges you can run and practice against!


thedamon / backbutton close bootstrap modal
Created Feb 28, 2014
Cause back button to close Bootstrap modal windows
View backbutton close bootstrap modal
$('div.modal').on('show', function() {
var modal = this;
var hash =;
window.location.hash = hash;
window.onhashchange = function() {
if (!location.hash){