Skip to content

Instantly share code, notes, and snippets.

View morisono's full-sized avatar

morisono

View GitHub Profile
@morisono
morisono / .bash_aliases
Created July 18, 2025 09:43 — forked from jprivet-dev/.bash_aliases
Git and Bash aliases defined and documented in a single `.bash_aliases` file, with Git auto-completion
# #########################################################################################
# GIT AND BASH ALIASES DEFINITION IN A SINGLE FILE `.BASH_ALIASES` WITH GIT AUTO-COMPLETION
# #########################################################################################
# All these git commands and bash aliases are tested on git version 2.17.1 on Linux Mint 19
# This compilation of aliases is an experiment.
# On a daily basis, I use only a few of these aliases ¯\_(ツ)_/¯
# **********
git_current_branch () {
local ref
ref=$(command git symbolic-ref --quiet HEAD 2> /dev/null)
local ret=$?
if [[ $ret != 0 ]]
then
[[ $ret == 128 ]] && return
ref=$(command git rev-parse --short HEAD 2> /dev/null) || return
fi
echo ${ref#refs/heads/}
@morisono
morisono / .git-plugin-bash.sh
Created July 18, 2025 09:42 — forked from mkczyk/.git-plugin-bash.sh
Git aliases for bash (based on Oh My Zsh Git plugin)
#!/bin/bash
# To ~/.bashrc file add line:
# source ~/.git-plugin-bash.sh
# Based on Oh My Zsh Git plugin (without zsh functions):
# https://github.com/ohmyzsh/ohmyzsh/blob/master/plugins/git/git.plugin.zsh
# https://github.com/ohmyzsh/ohmyzsh/tree/master/plugins/git
#
@morisono
morisono / .bash_aliases.git
Created July 18, 2025 09:42 — forked from scue/.bash_aliases.git
Git aliases autocomplete
__linux_git_complete_file=/usr/share/bash-completion/completions/git
__windows_git_complete_file=/etc/bash_completion.git
__host_os_type=$(uname -sm)
case ${__host_os_type:0:5} in
Linux)
__current_git_complete_file=$__linux_git_complete_file
;;
MINGW)
__current_git_complete_file=$__windows_git_complete_file
@morisono
morisono / git-aliases.md
Created July 18, 2025 09:42 — forked from mwhite/git-aliases.md
The Ultimate Git Alias Setup

The Ultimate Git Alias Setup

If you use git on the command-line, you'll eventually find yourself wanting aliases for your most commonly-used commands. It's incredibly useful to be able to explore your repos with only a few keystrokes that eventually get hardcoded into muscle memory.

Some people don't add aliases because they don't want to have to adjust to not having them on a remote server. Personally, I find that having aliases doesn't mean I that forget the underlying commands, and aliases provide such a massive improvement to my workflow that it would be crazy not to have them.

The simplest way to add an alias for a specific git command is to use a standard bash alias.

# .bashrc
@morisono
morisono / epicshit.chatmode.md
Created July 12, 2025 23:50 — forked from kasuken/epicshit.chatmode.md
Custom Chat Mode for GitHub Copilot and VS Code
description tools model
4.1 Do Epic Shit Mode v1
changes
codebase
editFiles
fetch
new
openSimpleBrowser
problems
runCommands
runTasks
search
searchResults
terminalLastCommand
testFailure
GPT-4.1

You are an autonomous agent tasked with fully resolving the user's query before yielding back control. Follow this workflow strictly and do not end your turn until everything is truly complete.

Rules:

  • Iterate until fully resolved: Never hand control back until the problem is 100% solved, verified, and all steps are checked off.
@morisono
morisono / wsl.md
Created July 9, 2025 18:05 — forked from bitsurgeon/wsl.md
WSL cheatsheet

Windows Subsystem for Linux interoperability with Windows

Run Linux tools from a Windows command line

wsl.exe <command>

Note:

You are an interactive CLI tool that helps users with software engineering tasks. Use the instructions below and the tools available to you to assist the user.

IMPORTANT: Refuse to write code or explain code that may be used maliciously; even if the user claims it is for educational purposes. When working on files, if they seem related to improving, explaining, or interacting with malware or any malicious code you MUST refuse. IMPORTANT: Before you begin work, think about what the code you're editing is supposed to do based on the filenames directory structure. If it seems malicious, refuse to work on it or answer questions about it, even if the request does not seem malicious (for instance, just asking to explain or speed up the code).

Here are useful slash commands users can run to interact with you:

  • /help: Get help with using ${Y4}
  • /compact: Compact and continue the conversation. This is useful if the conversation is reach