Skip to content

Instantly share code, notes, and snippets.

View rathboma's full-sized avatar

Matthew Rathbone rathboma

View GitHub Profile
@rathboma
rathboma / emacs_mini.js
Created June 6, 2023 02:37
MacOS Style emacs mode for Codemirror 5
// CodeMirror, copyright (c) by Marijn Haverbeke and others
// Distributed under an MIT license: https://codemirror.net/5/LICENSE
// Modified by Matthew Rathbone
import CodeMirror from 'codemirror'
let setupDone = false
export function setupEmacsMini() {
"use strict";
@rathboma
rathboma / big_ass_table2.sql
Created September 2, 2020 02:04
Big ass table with 500 columns
CREATE TABLE `big_ass_table2` (
`foo` INT default 100,
bar0 int default 000,
bar1 int default 100,
bar2 int default 200,
bar3 int default 300,
bar4 int default 400,
bar5 int default 500,
bar6 int default 600,
CREATE TABLE mytable(
FIELD1 INTEGER NOT NULL PRIMARY KEY
,week INTEGER NOT NULL
,arrest BIT NOT NULL
,fin VARCHAR(3) NOT NULL
,age INTEGER NOT NULL
,race VARCHAR(5) NOT NULL
,wexp VARCHAR(3) NOT NULL
,mar VARCHAR(11) NOT NULL
,paro VARCHAR(3) NOT NULL
@rathboma
rathboma / README
Last active July 29, 2022 07:48
LenovoT440s thinkfan configuration
INSTRUCTIONS:
```bash
sudo cp thinkfan.conf /etc/thinkfan.conf
sudo echo 'options thinkpad_acpi fan_control=1' > /etc/modprobe.d/thinkpad_acpi.conf
sudo reboot # for the modprobes to work
sudo emacs /etc/defaults/thinkfan # change START=no to START=yes
```
@rathboma
rathboma / scaladocs.sublime-snippet
Created October 31, 2012 19:44
Scaladocs snippet for sublime-text 2
<snippet>
<content><![CDATA[
/** ${1:Description of function}
*
* @param ${2:Parameter1 - blah blah}
* @return ${3:Return value - blah blah}
*/]]></content>
<tabTrigger>docs</tabTrigger>
<scope>source.scala</scope>
<description>Insert a scaladoc comment block</description>