Skip to content

Instantly share code, notes, and snippets.

View danielgormly's full-sized avatar

Daniel Gormly danielgormly

View GitHub Profile
@danielgormly
danielgormly / autoconfig.js
Created February 7, 2025 12:01
Firefox: Add ctrl+option+left/right to jump tabs
// Note this goes in /usr/lib/firefox/defaults/pref/autoconfig.js
pref("general.config.filename", "firefox.js");
pref("general.config.obscure_value", 0);
pref("general.config.sandbox_enabled", false);
@danielgormly
danielgormly / instructions.md
Created February 3, 2025 12:46
Removing Softbank Leica Phone LP-01 Bloatware

You will need Android Debug Bridge

First, some settings:

Display -> Customise Home

  • Turn off "Display Google app"
  • Turn off "Display Google Search Widget"

And the rest of the bloat

@danielgormly
danielgormly / keymap.jsonc
Last active February 7, 2025 10:11
zed-swap-lctrl-lsuper-macos-like-keymaps
// Zed keymap
//
// For information on binding keys, see the Zed
// documentation: https://zed.dev/docs/key-bindings
//
// To see the default key bindings run `zed: open default keymap`
// from the command palette.
[
{
"context": "Workspace",
@danielgormly
danielgormly / get-my-gamespot-games.js
Last active December 18, 2022 03:49
Pull ratings from your Gamespot profile and save as json
const { parse } = require('date-fns');
const { JSDOM } = require('jsdom');
const { writeFileSync } = require('fs');
async function main() {
const outputFile = 'output.json';
const outputData = [];
for (let i = 1; i <= 10; i++) {
const res = await fetch(`https://www.gamespot.com/profile/reviews/?page=${i}`, {
"credentials": "include",
@danielgormly
danielgormly / Dockerfile
Created March 5, 2018 03:12
Amazon Linux NPM Install
FROM amazonlinux
ENV VERSION="8.9.4"
ENV NVM_DIR="/root/.nvm"
RUN curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.31.0/install.sh | bash \
&& [ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" \
&& nvm install $VERSION
ENV PATH="${NVM_DIR}/versions/node/v${VERSION}/bin:${PATH}"
WORKDIR /var/task
@danielgormly
danielgormly / MiniKoa.js
Last active March 19, 2017 06:43
Microcosm of Koa's flow control
/*
MiniKoa ^.^
- In the real Koa, the module Koa-composer takes on the recursive behaviour.
- This still works with async functions because await will automatically convert resolved values into promises.
- The most notable difference of course is that this doesn't respond to an http request instead it just runs instantly with whatever context object you give it.
*/
class MiniKoa {
constructor() {
this.middleware = [];