Skip to content

Instantly share code, notes, and snippets.

View NickCrew's full-sized avatar

Nick Ferguson NickCrew

View GitHub Profile
@NickCrew
NickCrew / install-macos-dev-tools.sh
Created January 24, 2022 20:16
Install macOS Dev Tools
#!/usr/bin/env zsh
#
# Install dotfile dependencies
#
# {{{ Lib functions
local function dots_show_usage () {
echo "USAGE:"
echo " dots-tool-installer [neovim|devtools|langs|fonts]"
echo ""
@NickCrew
NickCrew / python-debug.json
Created January 20, 2022 19:16
Vimspector Generic Python
{
"configurations": {
"python-debug": {
"default": true,
"adapter": "debugpy",
"filetypes": [ "python" ],
"breakpoints": {
"exception": {
"all": "N",
"uncaught": "Y"
@NickCrew
NickCrew / tmux.conf
Created January 10, 2022 18:44
Tmux v1.8 Config
# Basic Tmux Config
# Compatible with version: 1.8
# Remap prefix to Ctrl+a
unbind C-b
set-option -g prefix C-a
bind-key C-a send-prefix
# Reload tmux config
bind r source-file ~/.tmux.conf
@NickCrew
NickCrew / .bashrc
Created January 10, 2022 18:34
Basic Bash RC File
set -o vi # use vi keybindings
@NickCrew
NickCrew / aliases.conf
Created January 4, 2022 16:35
Git CLI Aliases
[alias]
# Show git status
st = status
# Commit staged changes with editor
ct = commit
# Push to remote
pu = push
# Pull from remote
pl = pull
# Fetch remote data
@NickCrew
NickCrew / setup-python-macos.zsh
Created January 2, 2022 01:51
Setup python dev environment on macos
#!/usr/bin/env zsh
if [[ -z $ZDOTDIR ]]; then
ZDOTDIR=$HOME
fi
if ! command -v brew 1>/dev/null; then
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
fi
@NickCrew
NickCrew / install-tmux.sh
Created December 10, 2021 03:22
Install Tmux
#!/usr/bin/env bash
set -e
sudo apt-get update
sudo apt-get install -y bison gcc make pkg-config automake autoconf libncurses5-dev libevent-dev
mkdir -p ~/src
git clone https://github.com/tmux/tmux ~/src/tmux
@NickCrew
NickCrew / auto_syno
Last active November 6, 2021 18:26
Synology AutoFS
#!/bin/bash
# Copyright (c) 2000-2014 Synology Inc. All rights reserved.
################### NOTE ###################
#
# Adjust following settings to match your LDAP server.
#
# If using TLS or ldaps://, you have to append LDAP server's certificate to
# your client (in the file specified by tls_cacert in ldap.conf).
#
@NickCrew
NickCrew / cfg-install
Created August 23, 2021 00:45
User Config Install
#!/usr/bin/env bash
DOTS_REMOTE="https://github.com/NickCrew/dotfiles.git"
DOTS_REPO="$HOME/.dots.git"
DOTS_BRANCH=master
git clone --bare $DOTS_REMOTE $DOTS_REPO
function cfg {
git --git-dir=$DOTS_REPO --work-tree=$HOME $@
@NickCrew
NickCrew / functions.ps1
Created August 19, 2021 15:03
functions.ps1
Set-Alias -Name iconda -Value Initialize-Anaconda -Force
function Initialize-Anaconda {
# !! Contents within this block are managed by 'conda init' !!
(& "${HOME}\anaconda3\Scripts\conda.exe" "shell.powershell" "hook") | Out-String | Invoke-Expression
}
function Send-InputTo ($target) {
# Pipe output to args of $target