Skip to content

Instantly share code, notes, and snippets.

View ciarand's full-sized avatar

Ciaran Downey ciarand

View GitHub Profile
@ciarand
ciarand / README.md
Created January 24, 2014 04:43
Making xrandr modifications permanent with lightdm

Overview

xrandr is the easiest way to make a multiple display configuration work in Linux. Lightdm is my current display manager. This file explains how to make lightdm run an arbritrary script (in this case an xrandr script) on startup.

Here's the command we need:

@ciarand
ciarand / LICENSE
Last active August 24, 2021 06:02
Reading network stats from /proc/net/dev
This is free and unencumbered software released into the public domain.
Anyone is free to copy, modify, publish, use, compile, sell, or
distribute this software, either in source code form or as a compiled
binary, for any purpose, commercial or non-commercial, and by any
means.
In jurisdictions that recognize copyright laws, the author or authors
of this software dedicate any and all copyright interest in the
software to the public domain. We make this dedication for the benefit
tee /etc/ipsec.conf << EOF
config setup
dumpdir=/var/run/pluto/
#in what directory should things started by setup (notably the Pluto daemon) be allowed to dump core?
nat_traversal=yes
#whether to accept/offer to support NAT (NAPT, also known as "IP Masqurade") workaround for IPsec
virtual_private=%v4:10.0.0.0/8,%v4:192.168.0.0/16,%v4:172.16.0.0/12,%v6:fd00::/8,%v6:fe80::/10
#contains the networks that are allowed as subnet= for the remote client. In other words, the address ranges that may live behind a NAT router through which a client connects.
@ciarand
ciarand / resources.md
Last active December 26, 2015 09:49
A list of some of the resources we talked about on 10/24/13 at the OCPHP open discussion.
  • [Sylius][1], eCommerce library built on Symfony components
  • [PuPHPet][2], Vagrant config builder
  • [PHPStorm][3]
  • [Silex][4], PHP microframework built on Symfony components
  • [Behat][5], an "human friendly" testing language
  • [Mink][6], a web driver controller
  • [Apigility][7], an API creator by Zend
  • [PHPSpec][8], a BDD workflow tool
  • [Composer][10], a dependency management tool
  • [Vagrant][11], a virtualization management tool
@ciarand
ciarand / build.php
Created October 21, 2013 17:22
Minimal PHP build system example using lambdas
<?php
// Build system (minimal)
$builder = function (array $targets) {
foreach ($targets as $target) {
$target();
}
};
@ciarand
ciarand / make-it-work.sh
Last active December 23, 2015 02:09
Making R.A.T.7 work in Linux Mint
sudo cat rat7.xorg.conf >> /etc/X11/xorg.conf
sudo service mdm stop
sudo service mdm start
@ciarand
ciarand / Preferences.sublime-settings
Created July 25, 2013 23:06
Preferences.sublime-settings
{
// Thou shalt work with a real color scheme
"color_scheme": "Packages/Solarized Color Scheme/Solarized (light).tmTheme",
// But use classy tabs
"soda_classic_tabs": true,
// And the latest Soda theme
"theme": "Soda Light 3.sublime-theme",
// And thy font face shall be a robot
"font_face": "Droid Sans Mono",
<?php
$table = $this->getHelperSet()->get('table');
$table
->setHeaders(
array(
'',
'Absolute',
'Percent',
)
)
@ciarand
ciarand / _colors.scss
Created April 15, 2013 21:37
A listing of commonly used SCSS colors
/*========================================
= Solarized Colors =
========================================*/
$solarized-base03: #002B36;
$solarized-base02: #073642;
$solarized-base01: #586E75;
$solarized-base00: #657B83;
$solarized-base0: #839496;
$solarized-base1: #93A1A1;
@ciarand
ciarand / ciarand.zsh-theme
Created April 14, 2013 04:21
My custom ZSH theme
# Theme components and ideas shamelessly stolen from:
# [Agnoster](https://github.com/robbyrussell/oh-my-zsh/blob/master/themes/agnoster.zsh-theme) by @agnoster
# [Kardan](https://github.com/robbyrussell/oh-my-zsh/blob/master/themes/kardan.zsh-theme) by @kardan
# [Junkfood](https://github.com/robbyrussell/oh-my-zsh/blob/master/themes/junkfood.zsh-theme) by Tyler Cipriani
# Path settings
###############
# Set the user and host segments
prompt_host() {