Skip to content

Instantly share code, notes, and snippets.

@ljcl
ljcl / gitstat.sh
Created January 7, 2020 03:51
Graphing code quality over time
#!/bin/bash
prefix=''
# A more consistent way to handle week number could be good.
start_of_year=$(/bin/date -uj 123100002018 +%s)
seconds_in_week=$((7 * 24 * 60 * 60))
echo "\"date\",\"commit\",\"getErrorResponse\",\"Flow Any Types\",\"Flow Supressions\",\"Javascript files\",\"TODO\",\"noflow annotations\",\"css !important\",\"WIP commits\"";
for i in {0..52}; do
week_start=$((start_of_year + seconds_in_week * i))
date=$(/bin/date -juf %s $week_start +%+)
commit=$(git log "--before=$date" --max-count=1 --format=%H)
@ljcl
ljcl / userChrome.css
Last active September 26, 2019 11:28
Treestyletabs userChrome.css
@namespace url('http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul');
/*
Several tweaks to make treestyletabs a bit nicer
tip: Put the TST toolbar icon to the left of the navigation arrows
From FF69 onwards, set `toolkit.legacyUserProfileCustomizations.stylesheets` to true in about:config
*/
/* hide sidebar header for tree style tabs sidebar */
#sidebar-box[sidebarcommand='treestyletab_piro_sakura_ne_jp-sidebar-action'] #sidebar-header {
@ljcl
ljcl / keybase.md
Created February 8, 2017 22:50
keybase.md

Keybase proof

I hereby claim:

  • I am ljcl on github.
  • I am lukeclark (https://keybase.io/lukeclark) on keybase.
  • I have a public key whose fingerprint is 4E7D 2659 EF72 A760 CCD6 9C55 0D55 269A BDDF 3E93

To claim this, I am signing this object:

@ljcl
ljcl / post-commit
Created August 15, 2016 05:17
Add git commits to Harvest currently running timer
#!/usr/bin/env node
'use strict'
// https://lukeclark.com.au/posts/harvest-post-commit-hook-nodejs
// Assume dependencies are installed at the project, or
// required commands have been installed globally
var request = require('request')
// make the logOutput available anywhere
@ljcl
ljcl / readme.md
Last active May 3, 2016 05:39
Append commit to active harvest timer
@ljcl
ljcl / .csscomb.json
Created April 14, 2015 10:46
SCSS Organisation and Linting
{
"remove-empty-rulesets": true,
"always-semicolon": true,
"color-case": "lower",
"block-indent": " ",
"color-shorthand": true,
"element-case": "lower",
"unitless-zero": true,
"eof-newline": true,
"leading-zero": false,
@ljcl
ljcl / Reusable SCSS Mixins
Last active August 29, 2015 14:12
Useful SCSS mixins to speed up development time and reduce headaches.
A collection of useful, handy SCSS mixins which I reuse across my projects.
[View related article.](https://lukejclark.com/posts/more-useful-sass-mixins)