Skip to content

Instantly share code, notes, and snippets.

View griffgruff's full-sized avatar
💭
rocking

Anthony Griffiths griffgruff

💭
rocking
View GitHub Profile
@griffgruff
griffgruff / home-row-combo-keys.c
Last active September 8, 2024 12:29
home row combo keys
// --------------------------------------------------------
// KEY-COMBOS
//
// These are the double key presses
// Two keys pressed at the same time to produce one
// Getting the CMD CTRL keys under your finger tips
/*
|----------------+
| *SCMD | *SCMD |
@griffgruff
griffgruff / go.sh
Created April 16, 2024 13:33
just run
#!/usr/bin/env bash
# Getting tired of not knowing which npm command to run
# Well this is the answer
# It does use fzf.
# First off, this script allow us to just type : run
# Then you can just filter by command
# I was using ntl, but it is/was super slow.
# jq is another thing you might have to install
@griffgruff
griffgruff / dam.md
Last active March 5, 2024 10:57
sra-dam.md

ToDo

Setup some env vars

How to create a typed env file.

How to manage .env files

// Copyright 2022 Victor Lucachi (@victorlucachi)
// SPDX-License-Identifier: GPL-2.0-or-later
#pragma once
#define COMBO_TERM 25
#define COMBO_MUST_HOLD_MODS
#define COMBO_HOLD_TERM 175
#undef TAPPING_TERM
#define TAPPING_TERM 200
#define RETRO_TAPPING
@griffgruff
griffgruff / launch.json
Created July 24, 2023 15:40
ts-node-launch.json
{
"version": "0.2.0",
"configurations": [
{
"name": "Example",
"type": "node",
"request": "launch",
"runtimeExecutable": "node",
"runtimeArgs": ["--nolazy", "-r", "ts-node/register/transpile-only"],
"args": ["src/index.ts", "--example", "hello"],
@griffgruff
griffgruff / ranger-cheatsheet.md
Last active April 26, 2022 06:57 — forked from heroheman/ranger-cheatsheet.md
Ranger Cheatsheet

Ranger Cheatsheet

So I keep forgetting these

General

Shortcut Description
ranger Start Ranger
Q Quit Ranger
import { Component, AfterViewInit, ElementRef, ViewChild } from '@angular/core';
@Component({
selector: 'my-app',
templateUrl: './app.component.html',
styleUrls: [ './app.component.css' ]
})
export class AppComponent implements AfterViewInit {
name = 'Angular 8 by Example: ElementRef';
function traverse(arr, func) {
_.forEach(arr, function(obj) {
var keys = Object.keys(obj)
_.forEach(keys,function (key) {
if (_.isArray(obj[key])) {
traverse(obj[key], func)
}
func(key, obj);
})
});
import os
clear = lambda: os.system('cls')
worldList = [(3,3),(3,4),(3,2),(2,2),(4,3),(4,4),(4,5),(5,5)]
friendList = [(-1,-1),(0,-1),(1,-1),(-1,0),(1,0),(-1,1),(0,1),(1,1)]
def printWorld(x, y, cellAlive):
if ( cellAlive ):
@griffgruff
griffgruff / git.md
Last active April 26, 2022 07:38
Quick Git Guide

Quick Guide

git checkout -b web_testsrake

git commit -am "Message for my commit"

git config --global alias.lg "log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit"

Git Visual studio