Initial commit

This commit is contained in:
Javier Feliz 2025-07-08 22:37:54 -04:00
commit f4f7bf63be
9 changed files with 605 additions and 0 deletions

173
.bash_profile Executable file
View File

@ -0,0 +1,173 @@
# Aliases
alias vim="nvim"
alias nv="nvim"
alias nig="dig"
alias eza='eza'
alias ls='eza -lh --group-directories-first --icons'
alias lsn='eza'
# Quicker navigation
alias ..="cd .."
alias ...="cd ../.."
alias ....="cd ../../.."
alias .....="cd ../../../.."
# Enable aliases to be sudoed
alias sudo='sudo '
# Install and remove packages
alias install="sudo apt install -y"
# Config files
alias kittyc="nvim ~/.config/kitty"
alias helixc="nvim ~/.config/helix"
alias starc="nvim ~/.config/starship.toml"
function nvimc() {
cd "~/.config/nvim"
nvim .
}
# Git
# You must install Git first
alias gs='git status'
alias ga='git add -A'
alias gc='git commit -m' # requires you to type a commit message
alias grm='git rm $(git ls-files --deleted)'
alias gb="git checkout -b"
function commit() {
git add .
git commit -m "$1"
}
function push() {
branch=$(parse_git_branch)
git push -u origin "$branch"
}
# # Git branch details
function parse_git_dirty() {
[[ $(git status 2>/dev/null | tail -n1) != *"working directory clean"* ]]
}
function parse_git_branch() {
git branch --no-color 2>/dev/null | sed -e '/^[^*]/d' -e "s/* \(.*\)/\1$(parse_git_dirty)/"
}
# Docker aliases
alias dc="docker-compose"
alias bx="docker buildx"
alias de="docker exec -it"
alias dub="docker compose up -d --build"
alias dup="docker-compose up"
alias dwn="docker-compose down"
alias da="docker_artisan"
# Laravel & php
alias a="php artisan"
# Convenience
alias ep="nvim ~/.bash_profile"
alias rp="source ~/.bashrc && clear"
alias edithosts="nvim /etc/hosts"
alias cls="clear"
alias editpath="nvim /etc/paths"
alias home="cd ~"
alias projects="cd ~/projects"
alias co="code ."
alias locl="cd ~/Sites/local"
alias cdpl="cd deploy/local"
alias clipboard="xclip -selection clipboard"
# Laravel sail
alias sail='[ -f sail ] && sh sail || sh vendor/bin/sail'
alias sup="sail up -d"
alias sd="sail down"
alias sa="sail artisan"
alias sc="sail composer"
alias st="sail test"
alias stf="sail composer tf"
alias rebuild="sail down && sail build --no-cache && sail up -d"
# Temp
alias smp="sa migrate:rollback && sa migrate && clear && sa db:seed --class=SimpleMapSeeder"
alias stackartisan="docker exec -it stack-ems php /usr/src/myapp/artisan"
# Jigsaw
alias jig="vendor/bin/jigsaw"
# Golang
alias gr="go run ."
alias gmt="go mod tidy"
# Open something in the projects folder
function o() {
cd "$HOME/projects/$1"
}
function proj() {
lsn -ld ~/projects/* --color=never |
awk '{print $7}' |
fzf --reverse | xargs -I{} code {} -n && exit
}
function makepasswd() {
openssl rand -base64 16 | clipboard
echo "Password copied to clipboard"
}
function mountnewshares() {
sudo systemctl daemon-reload
sudo mount -a
}
function makerole() {
mkdir -p "roles/$1/tasks"
mkdir -p "roles/$1/defaults"
touch "roles/$1/tasks/main.yml"
touch "roles/$1/defaults/main.yml"
}
function pyvenv() {
python3 -m venv .venv
source .venv/bin/activate
}
function newsshkey() {
KEY_NAME="id_ed25519_$1"
KEY_PATH="$HOME/.ssh/$KEY_NAME"
ssh-keygen -t ed25519 -C "$1" -f "$KEY_PATH" -N ""
ssh-add "$KEY_PATH"
echo "Key created and added"
echo "Key: $KEY_NAME"
echo "Saved to: $KEY_PATH"
}
function listsshkeys() {
ls "$HOME/.ssh"
}
function copypublickey() {
KEY_NAME="$1"
KEY_PATH="$HOME/.ssh/$KEY_NAME"
cat "$KEY_PATH.pub" | clipboard
echo "Key copied to clipboard"
}
eval "$(starship init bash)"
. "$HOME/.cargo/env"
# Add composer global bin
export PATH="$PATH:$HOME/.config/composer/vendor/bin"
export PATH="$PATH:$HOME/go/bin"
export PATH="$PATH:/usr/local/go/bin"
export PATH="$PATH:$HOME/.config/herd-lite/bin"
# Created by `pipx` on 2025-06-17 18:51:39
export PATH="$PATH:/home/javi/.local/bin"
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

15
.bashrc Executable file
View File

@ -0,0 +1,15 @@
source ~/.bash_profile
# Editor used by CLI
export EDITOR="nvim"
export SUDO_EDITOR="$EDITOR"
. "$HOME/.cargo/env"
# Created by `pipx` on 2025-06-17 18:51:39
export PATH="$PATH:/home/javi/.local/bin"
export PATH="/home/javi/.config/herd-lite/bin:$PATH"
export PHP_INI_SCAN_DIR="/home/javi/.config/herd-lite/bin:$PHP_INI_SCAN_DIR"
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

143
fastfetch/config.jsonc Executable file
View File

@ -0,0 +1,143 @@
{
"$schema": "https://github.com/fastfetch-cli/fastfetch/raw/dev/doc/json_schema.json",
"logo": {
"padding": {
"top": 5,
"right": 6
}
},
"modules": [
"break",
{
"type": "custom",
"format": "\u001b[90m┌──────────────────────Hardware──────────────────────┐"
},
{
"type": "host",
"key": " PC",
"keyColor": "green"
},
{
"type": "cpu",
"key": "│ ├",
"showPeCoreCount": true,
"keyColor": "green"
},
{
"type": "gpu",
"key": "│ ├",
"detectionMethod": "pci",
"keyColor": "green"
},
{
"type": "display",
"key": "│ ├󱄄",
"keyColor": "green"
},
{
"type": "disk",
"key": "│ ├󰋊",
"keyColor": "green"
},
{
"type": "memory",
"key": "│ ├",
"keyColor": "green"
},
{
"type": "swap",
"key": "└ └󰓡 ",
"keyColor": "green",
},
{
"type": "custom",
"format": "\u001b[90m└────────────────────────────────────────────────────┘"
},
"break",
{
"type": "custom",
"format": "\u001b[90m┌──────────────────────Software──────────────────────┐"
},
{
"type": "os",
"key": " OS",
"keyColor": "yellow"
},
{
"type": "kernel",
"key": "│ ├",
"keyColor": "yellow"
},
{
"type": "packages",
"key": "│ ├󰏖",
"keyColor": "yellow"
},
{
"type": "shell",
"key": "└ └",
"keyColor": "yellow"
},
"break",
{
"type": "de",
"key": " DE",
"keyColor": "blue"
},
{
"type": "wm",
"key": "│ ├",
"keyColor": "blue"
},
{
"type": "wmtheme",
"key": "│ ├󰉼",
"keyColor": "blue"
},
{
"type": "icons",
"key": "│ ├󰀻",
"keyColor": "blue",
},
{
"type": "cursor",
"key": "│ ├",
"keyColor": "blue",
},
{
"type": "terminalfont",
"key": "│ ├",
"keyColor": "blue",
},
{
"type": "terminal",
"key": "└ └",
"keyColor": "blue"
},
{
"type": "custom",
"format": "\u001b[90m└────────────────────────────────────────────────────┘"
},
"break",
{
"type": "custom",
"format": "\u001b[90m┌────────────────────Uptime / Age────────────────────┐"
},
{
"type": "command",
"key": " OS Age ",
"keyColor": "magenta",
"text": "birth_install=$(stat -c %W /); current=$(date +%s); time_progression=$((current - birth_install)); days_difference=$((time_progression / 86400)); echo $days_difference days"
},
{
"type": "uptime",
"key": " Uptime ",
"keyColor": "magenta"
},
{
"type": "custom",
"format": "\u001b[90m└────────────────────────────────────────────────────┘"
},
"break",
]
}

143
fastfetch/fastfetch/config.jsonc Executable file
View File

@ -0,0 +1,143 @@
{
"$schema": "https://github.com/fastfetch-cli/fastfetch/raw/dev/doc/json_schema.json",
"logo": {
"padding": {
"top": 5,
"right": 6
}
},
"modules": [
"break",
{
"type": "custom",
"format": "\u001b[90m┌──────────────────────Hardware──────────────────────┐"
},
{
"type": "host",
"key": " PC",
"keyColor": "green"
},
{
"type": "cpu",
"key": "│ ├",
"showPeCoreCount": true,
"keyColor": "green"
},
{
"type": "gpu",
"key": "│ ├",
"detectionMethod": "pci",
"keyColor": "green"
},
{
"type": "display",
"key": "│ ├󱄄",
"keyColor": "green"
},
{
"type": "disk",
"key": "│ ├󰋊",
"keyColor": "green"
},
{
"type": "memory",
"key": "│ ├",
"keyColor": "green"
},
{
"type": "swap",
"key": "└ └󰓡 ",
"keyColor": "green",
},
{
"type": "custom",
"format": "\u001b[90m└────────────────────────────────────────────────────┘"
},
"break",
{
"type": "custom",
"format": "\u001b[90m┌──────────────────────Software──────────────────────┐"
},
{
"type": "os",
"key": " OS",
"keyColor": "yellow"
},
{
"type": "kernel",
"key": "│ ├",
"keyColor": "yellow"
},
{
"type": "packages",
"key": "│ ├󰏖",
"keyColor": "yellow"
},
{
"type": "shell",
"key": "└ └",
"keyColor": "yellow"
},
"break",
{
"type": "de",
"key": " DE",
"keyColor": "blue"
},
{
"type": "wm",
"key": "│ ├",
"keyColor": "blue"
},
{
"type": "wmtheme",
"key": "│ ├󰉼",
"keyColor": "blue"
},
{
"type": "icons",
"key": "│ ├󰀻",
"keyColor": "blue",
},
{
"type": "cursor",
"key": "│ ├",
"keyColor": "blue",
},
{
"type": "terminalfont",
"key": "│ ├",
"keyColor": "blue",
},
{
"type": "terminal",
"key": "└ └",
"keyColor": "blue"
},
{
"type": "custom",
"format": "\u001b[90m└────────────────────────────────────────────────────┘"
},
"break",
{
"type": "custom",
"format": "\u001b[90m┌────────────────────Uptime / Age────────────────────┐"
},
{
"type": "command",
"key": " OS Age ",
"keyColor": "magenta",
"text": "birth_install=$(stat -c %W /); current=$(date +%s); time_progression=$((current - birth_install)); days_difference=$((time_progression / 86400)); echo $days_difference days"
},
{
"type": "uptime",
"key": " Uptime ",
"keyColor": "magenta"
},
{
"type": "custom",
"format": "\u001b[90m└────────────────────────────────────────────────────┘"
},
"break",
]
}

80
kitty/current-theme.conf Executable file
View File

@ -0,0 +1,80 @@
# vim:ft=kitty
## name: Catppuccin-Mocha
## author: Pocco81 (https://github.com/Pocco81)
## license: MIT
## upstream: https://github.com/catppuccin/kitty/blob/main/mocha.conf
## blurb: Soothing pastel theme for the high-spirited!
# The basic colors
foreground #CDD6F4
background #1E1E2E
selection_foreground #1E1E2E
selection_background #F5E0DC
# Cursor colors
cursor #F5E0DC
cursor_text_color #1E1E2E
# URL underline color when hovering with mouse
url_color #F5E0DC
# Kitty window border colors
active_border_color #B4BEFE
inactive_border_color #6C7086
bell_border_color #F9E2AF
# OS Window titlebar colors
wayland_titlebar_color system
macos_titlebar_color system
# Tab bar colors
active_tab_foreground #11111B
active_tab_background #CBA6F7
inactive_tab_foreground #CDD6F4
inactive_tab_background #181825
tab_bar_background #11111B
# Colors for marks (marked text in the terminal)
mark1_foreground #1E1E2E
mark1_background #B4BEFE
mark2_foreground #1E1E2E
mark2_background #CBA6F7
mark3_foreground #1E1E2E
mark3_background #74C7EC
# The 16 terminal colors
# black
color0 #45475A
color8 #585B70
# red
color1 #F38BA8
color9 #F38BA8
# green
color2 #A6E3A1
color10 #A6E3A1
# yellow
color3 #F9E2AF
color11 #F9E2AF
# blue
color4 #89B4FA
color12 #89B4FA
# magenta
color5 #F5C2E7
color13 #F5C2E7
# cyan
color6 #94E2D5
color14 #94E2D5
# white
color7 #BAC2DE
color15 #A6ADC8

10
kitty/kitty.conf Executable file
View File

@ -0,0 +1,10 @@
include current-theme.conf
font_size 16.0
background_opacity 0.9
background_blur 1
hide_window_decorations yes
map ctrl+shift+t new_tab_with_cwd

8
kitty/kitty.conf.bak Executable file
View File

@ -0,0 +1,8 @@
font_size 16.0
background_opacity 0.7
background_blur 30
hide_window_decorations yes
map ctrl+shift+t new_tab_with_cwd

30
sync.sh Executable file
View File

@ -0,0 +1,30 @@
function intake() {
while read folder; do
echo "Intaking changes from $folder"
mkdir -p "$folder"
cp -r "$HOME/.config/$folder/." "./$folder"
done <tracked.txt
echo "Copying bash profile"
cp "$HOME/.bash_profile" ./.bash_profile
cp "$HOME/.bashrc" ./.bashrc
}
function put() {
while read folder; do
echo "Putting changes from $folder"
cp -r "./$folder" "$HOME/.config/$folder"
done <tracked.txt
echo "Putting bash profile"
cp ./.bash_profile "$HOME/.bash_profile"
cp ./.bashrc "$HOME/.bashrc"
}
function pushupdate() {
git add .
git commit -m "Update"
git push
}
$1

3
tracked.txt Normal file
View File

@ -0,0 +1,3 @@
kitty
fastfetch
lazygit