Skip to content

Instantly share code, notes, and snippets.

View ReactiveRaven's full-sized avatar

David Godfrey ReactiveRaven

View GitHub Profile
@ReactiveRaven
ReactiveRaven / gist:9348401
Last active December 16, 2022 18:30
Ubuntu memory tuning

Add these lines to the end of /etc/sysctl.conf:

vm.swappiness=5
vm.min_free_kbytes=122880
vm.vfs_cache_pressure=500

Run these commands as root:

sudo sysctl -w vm.swappiness=5;

sudo sysctl -w vm.min_free_kbytes=122880

Using the selenium server at http://127.0.0.1:4444/wd/hub
Feature: Login
As a user
I want to be able to log in to the app
So I can access its delicious juices
Scenario: Test it works # test/features/login.feature:6
Given I am on the start page # test/features/login.feature:7
@ReactiveRaven
ReactiveRaven / atom.sh
Created January 27, 2015 11:49
atom update ubuntu
#!/bin/bash
remver=`wget -O - https://atom.io/releases 2>/dev/null | grep "<h2>v" | cut -f 2 -d "v" | cut -f 1 -d " " | head -n 1 | tr -d " \n";`;
locver=`/usr/bin/atom --version | tr -d " \n"`;
if [ "$remver" != "$locver" ];
then
echo "outdated $locver -> $remver";
echo "Need sudo.";
sudo echo "Thank you.";
if [ -f /tmp/atom.deb ];
then