Skip to content

Instantly share code, notes, and snippets.

@iTrauco
Created January 4, 2025 20:50
Show Gist options
  • Save iTrauco/354f61a46fcfc35f8645098226c413a6 to your computer and use it in GitHub Desktop.
Save iTrauco/354f61a46fcfc35f8645098226c413a6 to your computer and use it in GitHub Desktop.
# If you come from bash you might have to change your $PATH.
# export PATH=$HOME/bin:$HOME/.local/bin:/usr/local/bin:$PATH
alias gistedit='function _gistedit(){ vim "$1"; local filename="$1"; gh gist create "$filename" --public; }; _gistedit'
alias gisteditdesc='function _gisteditdesc(){
local filename="$1";
if [ -z "$filename" ]; then
echo "Usage: gisteditdesc <filename>";
return 1;
fi;
vim "$filename";
local description;
read -p "Enter description for the Gist: " description;
gh gist create "$filename" --public --description "$description";
}; _gisteditdesc'
# Path to your Oh My Zsh installation.
export ZSH="$HOME/.oh-my-zsh"
# Set name of the theme to load --- if set to "random", it will
# load a random theme each time Oh My Zsh is loaded, in which case,
# to know which specific one was loaded, run: echo $RANDOM_THEME
# See https://github.com/ohmyzsh/ohmyzsh/wiki/Themes
ZSH_THEME="robbyrussell"
# Set list of themes to pick from when loading at random
# Setting this variable when ZSH_THEME=random will cause zsh to load
# a theme from this variable instead of looking in $ZSH/themes/
# If set to an empty array, this variable will have no effect.
# ZSH_THEME_RANDOM_CANDIDATES=( "robbyrussell" "agnoster" )
# Uncomment the following line to use case-sensitive completion.
# CASE_SENSITIVE="true"
# Uncomment the following line to use hyphen-insensitive completion.
# Case-sensitive completion must be off. _ and - will be interchangeable.
# HYPHEN_INSENSITIVE="true"
# Uncomment one of the following lines to change the auto-update behavior
# zstyle ':omz:update' mode disabled # disable automatic updates
# zstyle ':omz:update' mode auto # update automatically without asking
# zstyle ':omz:update' mode reminder # just remind me to update when it's time
# Uncomment the following line to change how often to auto-update (in days).
# zstyle ':omz:update' frequency 13
# Uncomment the following line if pasting URLs and other text is messed up.
# DISABLE_MAGIC_FUNCTIONS="true"
# Uncomment the following line to disable colors in ls.
# DISABLE_LS_COLORS="true"
# Uncomment the following line to disable auto-setting terminal title.
# DISABLE_AUTO_TITLE="true"
# Uncomment the following line to enable command auto-correction.
# ENABLE_CORRECTION="true"
# Uncomment the following line to display red dots whilst waiting for completion.
# You can also set it to another string to have that shown instead of the default red dots.
# e.g. COMPLETION_WAITING_DOTS="%F{yellow}waiting...%f"
# Caution: this setting can cause issues with multiline prompts in zsh < 5.7.1 (see #5765)
# COMPLETION_WAITING_DOTS="true"
# Uncomment the following line if you want to disable marking untracked files
# under VCS as dirty. This makes repository status check for large repositories
# much, much faster.
# DISABLE_UNTRACKED_FILES_DIRTY="true"
# Uncomment the following line if you want to change the command execution time
# stamp shown in the history command output.
# You can set one of the optional three formats:
# "mm/dd/yyyy"|"dd.mm.yyyy"|"yyyy-mm-dd"
# or set a custom format using the strftime function format specifications,
# see 'man strftime' for details.
# HIST_STAMPS="mm/dd/yyyy"
# Would you like to use another custom folder than $ZSH/custom?
# ZSH_CUSTOM=/path/to/new-custom-folder
# Which plugins would you like to load?
# Standard plugins can be found in $ZSH/plugins/
# Custom plugins may be added to $ZSH_CUSTOM/plugins/
# Example format: plugins=(rails git textmate ruby lighthouse)
# Add wisely, as too many plugins slow down shell startup.
plugins=(git)
source $ZSH/oh-my-zsh.sh
# User configuration
# export MANPATH="/usr/local/man:$MANPATH"
# You may need to manually set your language environment
# export LANG=en_US.UTF-8
# Preferred editor for local and remote sessions
# if [[ -n $SSH_CONNECTION ]]; then
# export EDITOR='vim'
# else
# export EDITOR='mvim'
# fi
# Compilation flags
# export ARCHFLAGS="-arch x86_64"
# Set personal aliases, overriding those provided by Oh My Zsh libs,
# plugins, and themes. Aliases can be placed here, though Oh My Zsh
# users are encouraged to define aliases within a top-level file in
# the $ZSH_CUSTOM folder, with .zsh extension. Examples:
# - $ZSH_CUSTOM/aliases.zsh
# - $ZSH_CUSTOM/macos.zsh
# For a full list of active aliases, run `alias`.
#
# Example aliases
# alias zshconfig="mate ~/.zshrc"
# alias ohmyzsh="mate ~/.oh-my-zsh"
alias addalias='python /home/trauco/gcp-cli-tool/gcp_cli_tool/scripts/add_alias.py'
alias cf='open https://console.cloud.google.com/functions'
alias bq='open https://console.cloud.google.com/bigquery'
alias gcs='open https://console.cloud.google.com/storage'
# alias log='open https://console.cloud.google.com/logs'
alias rnf='python /home/trauco/gcp-cli-tool/scripts/run_and_filter.py'
alias zinit='source ~/.zshrc'
alias capture_output='python /home/trauco/gcp-cli-tool/scripts/capture_output.py'
alias filter_errors='python /home/trauco/gcp-cli-tool/scripts/filter_errors.py'
alias run_and_filter='python /home/trauco/gcp-cli-tool/scripts/run_and_filter.py'
alias cleanup_output='python /home/trauco/gcp-cli-tool/scripts/cleanup_output.py'
export PATH=$PATH:/usr/local/bin
export PATH=$PATH:/usr/local/bin
export PATH=$PATH:/usr/local/bin
export PATH=$PATH:/usr/local/bin
export PATH=$PATH:/usr/local/bin
export OPENAI_API_KEY="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"
export GH_EDITOR=vim
# Terraform Aliases
alias tfa='terraform apply'
alias tfp='terraform plan'
alias tfi='terraform init'
function gistall() {
if [ "$#" -eq 0 ]; then
echo "No files provided. Usage: gistall <file1> <file2> ... <fileN>"
return 1
fi
echo "Creating a gist with the following files:"
for file in "$@"; do
echo "$file"
done
# Prompt for a description
echo "Enter a description for the gist:"
read -r description
# Create the gist
gh gist create "$@" --public -d "$description"
}
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
export NVM_DIR="$([ -z "${XDG_CONFIG_HOME-}" ] && printf %s "${HOME}/.nvm" || printf %s "${XDG_CONFIG_HOME}/nvm")"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
# >>> conda initialize >>>
# !! Contents within this block are managed by 'conda init' !!
__conda_setup="$('/home/trauco/miniconda3/bin/conda' 'shell.zsh' 'hook' 2> /dev/null)"
if [ $? -eq 0 ]; then
eval "$__conda_setup"
else
if [ -f "/home/trauco/miniconda3/etc/profile.d/conda.sh" ]; then
. "/home/trauco/miniconda3/etc/profile.d/conda.sh"
else
export PATH="/home/trauco/miniconda3/bin:$PATH"
fi
fi
unset __conda_setup
# <<< conda initialize <<<
function gistpriv() {
if [ "$#" -eq 0 ]; then
echo "No files provided. Usage: gistpriv <file1> <file2> ... <fileN>"
return 1
fi
echo "Creating a private gist with the following files:"
for file in "$@"; do
echo "$file"
done
# Prompt for a description
echo "Enter a description for the gist:"
read -r description
# Create the private gist
gh gist create "$@" --private -d "$description"
}
function gistpriv() {
if [ "$#" -eq 0 ]; then
echo "No files provided. Usage: gistpriv <file1> <file2> ... <fileN>"
return 1
fi
echo "Creating a private gist with the following files:"
for file in "$@"; do
echo "$file"
done
# Prompt for a description
echo "Enter a description for the gist:"
read -r description
# Create the private gist (default is secret unless --public is specified)
gh gist create "$@" -d "$description"
}
alias gistsecret='function _gistsecret() { vim "$1"; local filename="$1"; gh gist create "$filename"; }; _gistsecret'
alias smarkets-sample-data="/usr/bin/google-chrome --profile-directory=\"Profile 2\" --new-window \
https://drive.google.com/drive/folders/1crrGD2RynMnO6BrNM5UfpQh0WCeTZq_v \
https://docs.google.com/spreadsheets/d/1Vq6txwqtXoo35ljrqDvPYLogE0Jcmcqw \
https://docs.google.com/spreadsheets/d/1lKEffhMWXg6WdcPZwvehptkevBH8-2OQ \
https://docs.google.com/spreadsheets/d/1oBVBZhtderGC5EZs9KTZZQGI6Kq4hWl_"
alias clear-bucket="gsutil -m rm -r \"gs://cdor-gaming-output-v2/**\""
alias pyup="python3 -m venv venv && source venv/bin/activate"
alias pydy="deactivate"
alias structure="tree -I \"venv*|__pycache__|*.pyc|.git|*.egg-info|env|*.env|dist|build\" ."
alias structurelog='mkdir -p logs && timestamp=$(date +"%Y-%m-%d-%H%M%S") && filepath="logs/structure_${timestamp}.md" && if [ -e "$filepath" ]; then filepath="logs/structure_${timestamp}_$RANDOM.md"; fi && tree -I "venv*|__pycache__|*.pyc|.git|*.egg-info|env|*.env|dist|build|dev-tools|logs|trackers" . > "$filepath"'
alias pyasss="source $(pwd)/venv/bin/activate"
alias pipin="pip3 install -r $(pwd)/requirements.txt"
alias pipout="pip3 freeze > $(pwd)/requirements.txt"
alias structurelog="mkdir -p logs && timestamp=$(date +%Y-%m-%d_%H%M_EST) && filepath=logs/structure_${timestamp}.md && if [ -e \$filepath ]; then filepath=logs/structure_${timestamp}_\$RANDOM.md; fi && tree -I \"venv*|__pycache__|*.pyc|.git|*.egg-info|env|*.env|dist|build\" . > \$filepath"
# # 🌐 Chrome Profile Alias
# alias gpt1="google-chrome --profile-directory="Profile 1""
# # 🌐 Chrome Profile Alias
# alias test-launch="google-chrome --profile-directory="Profile 1" "https://neopets.com""
# # 🌐 Chrome Profile Alias - Created by Chrome Profile Manager
# alias personal-chrome="google-chrome --profile-directory="Profile 1" --new-window "https://github.com/itrauco""
# # 🌐 Chrome Profile Alias - Created by Chrome Profile Manager
# alias test-chrome="/usr/bin/google-chrome --profile-directory=\"Profile 1\" --new-window https://msn.com"
# # 🌐 Chrome Profile Alias - Created by Chrome Profile Manager
# alias personal-chrome-test="/usr/bin/google-chrome --profile-directory=\"Profile 1\" --new-window https://yahoo.com"
# # 🌐 Chrome Profile Alias - Created by Chrome Profile Manager
# alias claude1="/usr/bin/google-chrome --profile-directory=\"Default\" --new-window https://claude.ai"
# # 🌐 Chrome Profile Alias - Created by PyBro CLI
# alias bc-chrome="/usr/bin/google-chrome --profile-directory="Profile 4" --new-window "https://botcopy.com""
# # 🌐 Chrome Profile Alias - Created by PyBro CLI
# alias voicemail="/usr/bin/google-chrome --profile-directory="Profile 3" --new-window "https://trau.co""
# # 🌐 Chrome Profile Alias - Created by PyBro CLI
# alias np-chrome="/usr/bin/google-chrome --profile-directory="Profile 6" --new-window "https://ddd.trau.co""
# # 🌐 Chrome Profile Alias - Created by PyBro CLI
# alias claude-dev="/usr/bin/google-chrome --profile-directory=\"Profile 10\" --new-window "https://claude.ai""
# # 🌐 Chrome Profile Alias - Created by PyBro CLI
# alias test-personal-linkedin="/usr/bin/google-chrome --profile-directory=\"Profile 1\" --new-window "https://linkedin.com""
# # 🌐 Chrome Profile Alias - Created by PyBro CLI
# alias cdor-crf='/usr/bin/google-chrome --profile-directory="Profile 12" --new-window '"'"'https://console.cloud.google.com/functions/list?referrer=search&hl=en&project=dor-gaming-data-test'"'"''
# alias cdor-bq='/usr/bin/google-chrome --profile-directory="Profile 12" --new-window '"'"'https://console.cloud.google.com/bigquery?hl=en&project=dor-gaming-data-test&ws=!1m0'"'"''
# alias cdor-gcs='/usr/bin/google-chrome --profile-directory="Profile 12" --new-window '"'"'https://console.cloud.google.com/storage/browser?hl=en&project=dor-gaming-data-test&prefix=&forceOnBucketsSortingFiltering=true'"'"''
# alias ebay='open -n -a "Google Chrome" --args Ebay.com --profile-directory="Profile 1" 'Ebay.com''
# AI
# Anthropic
alias claude1='/usr/bin/google-chrome --profile-directory="Profile 14" --new-window '"'"'https://claude.ai'"'"''
alias claude2='/usr/bin/google-chrome --profile-directory="Profile 16" --new-window '"'"'https://claude.ai'"'"''
alias claude3='/usr/bin/google-chrome --profile-directory="Profile 13" --new-window '"'"'https://claude.ai'"'"''
alias claude4='/usr/bin/google-chrome --profile-directory="Profile 17" --new-window '"'"'https://claude.ai'"'"''
alias claude-personal='/usr/bin/google-chrome --profile-directory="Profile 1" --new-window '"'"'https://claude.ai'"'"''
alias claude-dev='/usr/bin/google-chrome --profile-directory="Default" --new-window '"'"'https://claude.ai'"'"''
# OpenAI
alias openai-personal='/usr/bin/google-chrome --profile-directory="Default" --new-window '"'"'https://claude.ai'"'"''
alias gifme="~/scripts/peek_at_cursor.sh"
alias config='git --git-dir=/home/trauco/mad-scientist-linux --work-tree=/home/trauco'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment