Skip to content

Instantly share code, notes, and snippets.

View huntlyc's full-sized avatar

Huntly Cameron huntlyc

View GitHub Profile
@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active April 20, 2025 21:04
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@icebreaker
icebreaker / clear-screen.php
Created November 22, 2012 09:30
PHP - clear screen recipe
<?php
function cls()
{
print("\033[2J\033[;H");
}
echo "hello world";
cls();
@robmiller
robmiller / .gitconfig
Created July 17, 2013 07:52
Some useful Git aliases that I use every day
#
# Working with branches
#
# Get the current branch name (not so useful in itself, but used in
# other aliases)
branch-name = "!git rev-parse --abbrev-ref HEAD"
# Push the current branch to the remote "origin", and set it to track
# the upstream branch
publish = "!git push -u origin $(git branch-name)"
// Add the div to wrap the image on the archive pages
add_action( 'woocommerce_before_shop_loop_item_title', create_function('', 'echo "<div class=\"archive-img-wrap\">";'), 5, 2);
add_action( 'woocommerce_before_shop_loop_item_title',create_function('', 'echo "</div>";'), 12, 2);
// If there is sub categories on the archive page add a wrap around their images as well
add_action( 'woocommerce_before_subcategory_title', create_function( '', 'echo "<div class=\"sub-archive-img-wrapper\">";'), 5, 2 );
add_action( 'woocommerce_before_subcategory_title', create_function( '', 'echo "</div>";' ), 12, 2 );
@paulallies
paulallies / gist:0052fab554b14bbfa3ef
Last active August 3, 2024 16:45
Remove node_modules from git repo
#add 'node_modules' to .gitignore file
git rm -r --cached node_modules
git commit -m 'Remove the now ignored directory node_modules'
git push origin <branch-name>
@neuro-sys
neuro-sys / amstrad_cpc.md
Last active July 4, 2024 10:23
Amstrad CPC 464/6128 Programming Resources

Amstrad CPC 464/6128 Programming Resources

A collection of information gathered from various resources into a single document to be able to program for Amstrad CPC 464/6128 machines.

Hardware

CPC has the following components on the mainboard:

<!DOCTYPE html>
<html>
<head>
<title>1 | Safari Bug</title>
<style type="text/css">
body {
margin: 0 auto;
max-width: 40em;
width: 88%;