Skip to content

Instantly share code, notes, and snippets.

View BrianGilbert's full-sized avatar

Brian Gilbert BrianGilbert

View GitHub Profile
@BrianGilbert
BrianGilbert / gitHub-flavored-css-for-quiver.css
Last active September 8, 2021 08:56
GitHub flavoured css for Quiver
```css
/*
Github flavoured CSS for Quiver Note app.
http://happenapps.com)
https://github.com/HappenApps/Quiver
https://twitter.com/happenapps
Acknowledgments:
Modified version of https://gist.github.com/kcamcam/225a16f32409f0ae66f61569d6f706fc
@BrianGilbert
BrianGilbert / console.sql
Created August 10, 2016 04:23 — forked from anonymous/console.sql
Project machine names that depend on project machine name
SELECT DISTINCT fdfpmn.field_project_machine_name_value, pdd.dependency
FROM project_dependency_dependency pdd
LEFT JOIN project_dependency_component pdc ON pdc.component_id = pdd.component_id
LEFT JOIN field_data_field_release_project fdfrp ON fdfrp.entity_id = pdc.release_nid
LEFT JOIN field_data_field_project_machine_name fdfpmn on fdfpmn.entity_id = fdfrp.field_release_project_target_id
WHERE pdd.dependency IN (SELECT DISTINCT pdc.name FROM project_dependency_dependency pdd
LEFT JOIN project_dependency_component pdc ON pdc.component_id = pdd.component_id
LEFT JOIN field_data_field_release_project fdfrp ON fdfrp.entity_id = pdc.release_nid
LEFT JOIN field_data_field_project_machine_name fdfpmn on fdfpmn.entity_id = fdfrp.field_release_project_target_id
WHERE fdfpmn.field_project_machine_name_value = 'context')
# prevent the creation of .DS_Store files on network drives
# http://hints.macworld.com/article.php?story=2005070300463515
defaults write com.apple.desktopservices DSDontWriteNetworkStores true
#---------------------------------------------------------------------
# Disable/enable Dashboard:
# http://hints.macworld.com/article.php?story=20050723123302403
defaults write com.apple.dashboard mcx-disabled -boolean YES
<style>
.twitter-btn {
font: normal normal normal 13px/26px 'Helvetica Neue',Arial,sans-serif;
height: 28px;
border-radius: 4px;
max-width: 100%;
box-sizing: border-box;
position: relative;
background-color: #F8F8F8;
@BrianGilbert
BrianGilbert / pngout.rb
Last active March 11, 2016 17:35 — forked from paulredmond/pngout.rb
PNGOut Homebrew Formula
require 'formula'
class Pngout < Formula
url 'http://static.jonof.id.au/dl/kenutils/pngout-20130221-darwin.tar.gz'
homepage 'http://www.jonof.id.au/kenutils'
sha256 '995cc1df35e68b723c8143ad82c058be763f9af4fc373894ec74de3e7f18d0dd'
version '20130221'
def install
prefix.install Dir['*']
@BrianGilbert
BrianGilbert / nginx_static_include.conf
Last active September 8, 2017 11:07 — forked from omega8cc/gist:1677848
Create it as: /var/aegir/config/includes/nginx_static_include.conf
#######################################################
### nginx compact basic configuration start
#######################################################
###
### deny crawlers and bots without 403 response
###
if ($http_user_agent ~* (HTTrack|HTMLParser|libwww|wget|AutomaticSiteMap|bot) ) {
return 444;
}
@BrianGilbert
BrianGilbert / nginx_wp_include.conf
Last active April 25, 2022 11:55 — forked from omega8cc/gist:1677835
Create it as: /var/aegir/config/includes/nginx_wp_include.conf and add it in your custom vhost eg. https://gist.github.com/BrianGilbert/6227181
#######################################################
### nginx.conf site wp vhost include start
#######################################################
###
### deny crawlers without 403 response
###
if ($http_user_agent ~* (HTTrack|HTMLParser|libwww|wget) ) {
return 444;
}