Skip to content

lambdaFunctions/setup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 

Repository files navigation

SETUP

TERMINAL

CUSTOM .zshrc

  • Content of .zshrc:
## NEOVIM

export NVM_DIR="$HOME/.nvm"
# This loads nvm
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"
# This loads nvm bash_completion
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion"

alias vim="nvim"

# Preferred editor for local and remote sessions
if [[ -n $SSH_CONNECTION ]]; then
  export EDITOR='vim'
else
  export EDITOR='nvim'
fi

## PYTHON

# PYENV
export PATH="$HOME/.pyenv/bin:$PATH"
eval "$(pyenv init -)"
eval "$(pyenv virtualenv-init -)"

# Poetry
export PATH="/Users/paulo/.local/bin:$PATH"

### ALIASES

alias ll="ls -l"

TABBY

  • Font: Andale Mono 14
  • Settings: Appearence -> Allow font ligature

    Para mostrar os icones do Yazi

  • Color Scheme: Brogrammer
  • Notas:
    • Adicionar atalho para resize de splitted windows

OH MY ZSH

  • Tema: paulo
  • Content of paulo.zsh-theme in ~/.oh-my-zsh/themes:
function git_last_commit() {
  if git rev-parse --git-dir > /dev/null 2>&1; then
    local commit=$(git log -1 --pretty=format:'%h' 2>/dev/null)
    echo "[%{$fg[yellow]%}${commit}%{$reset_color%}]"
  fi
}

if [[ "$TERM" != "dumb" ]] && [[ "$DISABLE_LS_COLORS" != "true" ]]; then
  PROMPT='%{$fg[green]%}%n%{$reset_color%}@%{$fg[green]%}%m%{$reset_color%} %{$fg[white]%}%3~%{$reset_color%}$(git_prompt_info)$(git_last_commit)
λ '
    ZSH_THEME_GIT_PROMPT_PREFIX=" [%{$fg[green]%}"
    ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}]"
    ZSH_THEME_GIT_PROMPT_DIRTY=""
    ZSH_THEME_GIT_PROMPT_CLEAN=""

    # display exitcode on the right when >0
    return_code="%(?..%{$fg[red]%}%? ↵%{$reset_color%})"

    RPROMPT='${return_code}$(git_prompt_status)%{$reset_color%}'

    ZSH_THEME_GIT_PROMPT_ADDED="%{$fg[green]%} ✚"
    ZSH_THEME_GIT_PROMPT_MODIFIED="%{$fg[blue]%} ✹"
    ZSH_THEME_GIT_PROMPT_DELETED="%{$fg[red]%} ✖"
    ZSH_THEME_GIT_PROMPT_RENAMED="%{$fg[magenta]%} ➜"
    ZSH_THEME_GIT_PROMPT_UNMERGED="%{$fg[yellow]%} ═"
    ZSH_THEME_GIT_PROMPT_UNTRACKED="%{$fg[cyan]%} ✭"
else
    PROMPT='[%n@%m:%~$(git_prompt_info)]
λ '

    ZSH_THEME_GIT_PROMPT_PREFIX=" on"
    ZSH_THEME_GIT_PROMPT_SUFFIX=""
    ZSH_THEME_GIT_PROMPT_DIRTY=""
    ZSH_THEME_GIT_PROMPT_CLEAN=""

    # display exitcode on the right when >0
    return_code="%(?..%? ↵)"

    RPROMPT='${return_code}$(git_prompt_status)'

    ZSH_THEME_GIT_PROMPT_ADDED=""
    ZSH_THEME_GIT_PROMPT_MODIFIED=""
    ZSH_THEME_GIT_PROMPT_DELETED=""
    ZSH_THEME_GIT_PROMPT_RENAMED=""
    ZSH_THEME_GIT_PROMPT_UNMERGED=""
    ZSH_THEME_GIT_PROMPT_UNTRACKED=""
fi

WEZTERM

Create a .wezterm.lua in home directory:

local wezterm = require("wezterm")

local config = wezterm.config_builder()

config.window_decorations = "RESIZE"

local opacity = 0.95
 
config.window_background_opacity = opacity
config.macos_window_background_blur = 30

config.keys = {
    -- Page Management
    { key = "o", mods = "ALT", action = wezterm.action.SplitVertical { domain = "CurrentPaneDomain" }},
    { key = "v", mods = "ALT", action = wezterm.action.SplitHorizontal { domain = "CurrentPaneDomain" }},

    -- Pane Navigation
    { key = "LeftArrow", mods = "ALT", action = wezterm.action.ActivatePaneDirection "Left" },
    { key = "RightArrow", mods = "ALT", action = wezterm.action.ActivatePaneDirection "Right" },
    { key = "UpArrow", mods = "ALT", action = wezterm.action.ActivatePaneDirection "Up" },
    { key = "DownArrow", mods = "ALT", action = wezterm.action.ActivatePaneDirection "Down" },
}

return config

NEOVIM

Installation and Setup

Just copy the nvim/ folder to your ~/.config/

Plugin Manager

All the installed plugins are listed in the init.lua

LSP Details

ref: List of LSP server names: https://github.com/mattn/vim-lsp-settings
ref: Neovim LSP config doc: https://neovim.io/doc/user/lsp.html

Steps

  • 1: Install the language server in in the machine (brew install language-server-here for example)
  • 2: Creat the language-server.lua file in the /lsp folder
  • 3: Use the `vim.lsp.enable("language-server-here")

COLOR SCHEME

The color scheme used is customized by me for VSCode, so to use it in nvim we need to convert it into nvim syntax. Use https://github.com/viniciusmuller/djanho# project for that.

AEROSPACE

  • Gaps settings: [gaps] inner.horizontal = 7 inner.vertical = 7 outer.left = 15 outer.bottom = 5 outer.top = 5 outer.right = 15

YAZI

Global Installation and Setup

brew install yazi ffmpegthumbnailer ffmpeg sevenzip jq poppler fd ripgrep fzf zoxide imagemagick font-symbols-only-nerd-font

Paste in /zshrc:

function y() {
	local tmp="$(mktemp -t "yazi-cwd.XXXXXX")" cwd
	yazi "$@" --cwd-file="$tmp"
	if cwd="$(command cat -- "$tmp")" && [ -n "$cwd" ] && [ "$cwd" != "$PWD" ]; then
		builtin cd -- "$cwd"
	fi
	rm -f -- "$tmp"
}

Theme

Install the theme:

ya pkg add gosxrgxx/flexoki-dark

Create a file named theme.toml in .config/yazi/ and paste: [flavor] dark = "flexoki-dark"

FUZZY FINDER

  • fzf: brew install fzf

DOCKER

GIT

PROGRAMMING

  • Pyenv
  • Rust

CHECK LATER

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published