Skip to content

Instantly share code, notes, and snippets.

Avatar

Adam Gerthel AdamGerthel

  • Gotterdammerung
  • Malmö, Sweden
View GitHub Profile
@AdamGerthel
AdamGerthel / my-manifest.pp
Last active Aug 29, 2015
My personal manifest for OddBoxen
View my-manifest.pp
class people::myGitHubUsername {
# Homebrew
package { "couchdb":
ensure => present
}
# NodeJS modules
nodejs::module { 'hoodie-cli':
node_version => 'v0.10'
@AdamGerthel
AdamGerthel / disable_ajax.js
Created Mar 11, 2014
Useful snippet for theming Drupal ajax throbbers. Execute it in the console and it stops all future ajax requests from working. The throbbers will be displayed but never removed.
View disable_ajax.js
XMLHttpRequest = function(){};
XMLHttpRequest.prototype = {
open: function(){},
send: function(){}
};
@AdamGerthel
AdamGerthel / apache-https-htaccess-rewrite
Created Aug 22, 2014
Move all visitors to HTTPS version of site
View apache-https-htaccess-rewrite
# Move all visitors to HTTPS version of site
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
View jquery.equalRowHeights.js
/**
* jQuery equalRowHeights plugin.
*
* This is a small plugin that handles equalHeights in a reponsive
* way, meaning that it handles rows as well.
*
* Code from http://codepen.io/micahgodbolt/pen/FgqLc
*
*/
@AdamGerthel
AdamGerthel / holacracy-terms-sv
Last active Aug 29, 2015
Holacracy på svenska
View holacracy-terms-sv
accountability,ansvarsområde
amend,
circle,krets
core circle,huvudkrets
core circle member,huvudkretsmedlem
cross link policy,korslänkspolicy
domain,domän
facilitator,facilitator
focus,fokus
governance meeting,kretsmöte
View hemnet_ad.html
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta name='viewport' content='width=device-width, initial-scale=1, maximum-scale=1'>
<style>
/* http://meyerweb.com/eric/tools/css/reset/
v2.0 | 20110126
License: none (public domain)
*/
html, body, div, span, applet, object, iframe,
@AdamGerthel
AdamGerthel / fdt.ini
Last active Oct 28, 2015
O&G standardfil för FDT
View fdt.ini
; Detta är standardinställningar för FDT för O&G.
; Innehållet ska kopieras in i FDT.ini-filen i programmets katalog
; på aktuell dator och därefter ev. anpassas (sökvägar m.m.)
[Katalog]
Program=C:\Program Files\FDT\Avance
Rapport=Z:\Avance\Rapport
Data=Z:\Avance\Data
[Allmänt]
RödaTråden=Nej
Klient=000
@AdamGerthel
AdamGerthel / rpaf.ini
Last active Dec 21, 2015
Apache mod_rpaf configuration used in combination with Varnish. When using Varnish the $SERVER variable remote_addr is set to the Varnish server IP instead of the client ip (site visitor). If Varnish is configured to send X-Forwarded-For headers containing the client IP, then mod_rpaf can use that information and set remote_addr to the client IP…
View rpaf.ini
<IfModule rpaf_module>
RPAFenable On
# When enabled, take the incoming X-Host header and
# update the virtualhost settings accordingly:
RPAFsethostname On
# Define which IP's are your frontend proxies that sends
# the correct X-Forwarded-For headers:
RPAFproxy_ips 123.123.123.123 10.0.0.2 127.0.0.1
@AdamGerthel
AdamGerthel / localstorage.html
Last active Apr 15, 2017
Local Storage example
View localstorage.html
<!doctype html>
<html>
<head>
<title>Local Storage Demo</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<script src="https://code.jquery.com/jquery-1.11.0.min.js"></script>
<style>
body {
font-family: arial;
}
@AdamGerthel
AdamGerthel / senapskålspesto.md
Last active Jan 24, 2018
Pesto Cavolo di Senape
View senapskålspesto.md

En trevlig liten ruccolapesto/röra som dessutom är helt vegansk och väldigt näringsrik.

  • 6 dl ruccola
  • 1,5 dl olivolja
  • 4 matskedar näringsjäst (nutritional yeast)
  • 3 dl cashewnötter
  • 1 Vitlöksklyfta (pressad)
  • 4 tsk salt

Lägg nötterna i en kastrull och täck med vatten. Koka dem i ca. 10 minuter tills de mjuknat.