Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Swap out prezto for a minimal shell config
- Loading branch information
1 parent
d28930a
commit fa7ca48
Showing
7 changed files
with
270 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
alias ll="ls -l --color" | ||
alias la="ls -la --color" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# | ||
# Provides for an easier use of SSH by setting up ssh-agent. | ||
# | ||
# Authors: | ||
# Sorin Ionescu <sorin.ionescu@gmail.com> | ||
# | ||
# Source (adapted from): | ||
# https://github.com/sorin-ionescu/prezto/tree/master/modules/ssh | ||
# | ||
|
||
# Return if requirements are not found. | ||
if (( ! $+commands[ssh-agent] )); then | ||
return 1 | ||
fi | ||
|
||
# Set the path to the SSH directory. | ||
_ssh_dir="$HOME/.ssh" | ||
|
||
# Set the path to the environment file if not set by another module. | ||
_ssh_agent_env="${_ssh_agent_env:-${XDG_CACHE_HOME:-$HOME/.cache}/prezto/ssh-agent.env}" | ||
|
||
# Set the path to the persistent authentication socket. | ||
_ssh_agent_sock="${XDG_CACHE_HOME:-$HOME/.cache}/prezto/ssh-agent.sock" | ||
|
||
# Start ssh-agent if not started. | ||
if [[ ! -S "$SSH_AUTH_SOCK" ]]; then | ||
# Export environment variables. | ||
source "$_ssh_agent_env" 2> /dev/null | ||
|
||
# Start ssh-agent if not started. | ||
if ! ps -U "$LOGNAME" -o pid,ucomm | grep -q -- "${SSH_AGENT_PID:--1} ssh-agent"; then | ||
mkdir -p "$_ssh_agent_env:h" | ||
eval "$(ssh-agent | sed '/^echo /d' | tee "$_ssh_agent_env")" | ||
fi | ||
fi | ||
|
||
# Create a persistent SSH authentication socket. | ||
if [[ -S "$SSH_AUTH_SOCK" && "$SSH_AUTH_SOCK" != "$_ssh_agent_sock" ]]; then | ||
mkdir -p "$_ssh_agent_sock:h" | ||
ln -sf "$SSH_AUTH_SOCK" "$_ssh_agent_sock" | ||
export SSH_AUTH_SOCK="$_ssh_agent_sock" | ||
fi | ||
|
||
# Clean up. | ||
unset _ssh_{dir,identities} _ssh_agent_{env,sock} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,129 @@ | ||
[aws] | ||
disabled = true | ||
|
||
[battery] | ||
disabled = true | ||
|
||
[character] | ||
success_symbol = "[⤚](bold green)" | ||
error_symbol = "[⤚](bold red)" | ||
vicmd_symbol = "[⤙](bold green)" | ||
|
||
[cmake] | ||
disabled = true | ||
|
||
[conda] | ||
disabled = true | ||
|
||
[crystal] | ||
disabled = true | ||
|
||
[dart] | ||
disabled = true | ||
|
||
# [directory] | ||
|
||
# [docker_context] | ||
|
||
[dotnet] | ||
disabled = true | ||
|
||
[elixir] | ||
disabled = true | ||
|
||
[elm] | ||
disabled = true | ||
|
||
[env_var] | ||
disabled = true | ||
|
||
[erland] | ||
disabled = true | ||
|
||
[gcloud] | ||
disabled = true | ||
|
||
# [git_branch] | ||
|
||
# [git_commit] | ||
|
||
# [git_state] | ||
|
||
# [git_status] | ||
|
||
[golang] | ||
disabled = true | ||
|
||
# [hostname] | ||
|
||
# [java] | ||
|
||
# [jobs] | ||
|
||
[julia] | ||
disabled = true | ||
|
||
# [kubernetes] | ||
|
||
# [line_break] | ||
|
||
[lua] | ||
disabled = true | ||
|
||
# [memory_usage] | ||
|
||
# [hg_branch] | ||
|
||
[nim] | ||
disabled = true | ||
|
||
[nix_shell] | ||
disabled = true | ||
|
||
# [nodejs] | ||
|
||
# [package] | ||
|
||
[ocaml] | ||
disabled = true | ||
|
||
[openstack] | ||
disabled = true | ||
|
||
[perl] | ||
disabled = true | ||
|
||
[php] | ||
disabled = true | ||
|
||
# [python] | ||
|
||
[ruby] | ||
disabled = true | ||
|
||
# [rust] | ||
|
||
# [shlvl] | ||
|
||
[singularity] | ||
disabled = true | ||
|
||
[swift] | ||
disabled = true | ||
|
||
# [status] | ||
|
||
# [terraform] | ||
|
||
# [time] | ||
|
||
# [username] | ||
|
||
[zig] | ||
disabled = true | ||
|
||
[custom] | ||
disabled = true | ||
|
||
[purescript] | ||
disabled = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
# | ||
# Executes commands at login pre-zshrc. | ||
# | ||
# Authors: | ||
# Sorin Ionescu <sorin.ionescu@gmail.com> | ||
# | ||
# Source (adapted from): | ||
# https://github.com/sorin-ionescu/prezto/tree/master/runcoms | ||
# | ||
|
||
# | ||
# Browser | ||
# | ||
|
||
if [[ "$OSTYPE" == darwin* ]]; then | ||
export BROWSER='open' | ||
fi | ||
|
||
# | ||
# Editors | ||
# | ||
|
||
export EDITOR='nvim' | ||
export VISUAL='nvim' | ||
export PAGER='less' | ||
|
||
# | ||
# Language | ||
# | ||
|
||
if [[ -z "$LANG" ]]; then | ||
export LANG='en_US.UTF-8' | ||
fi | ||
|
||
# | ||
# Paths | ||
# | ||
|
||
# Ensure path arrays do not contain duplicates. | ||
typeset -gU cdpath fpath mailpath path | ||
|
||
# Set the list of directories that cd searches. | ||
# cdpath=( | ||
# $cdpath | ||
# ) | ||
|
||
# Set the list of directories that Zsh searches for programs. | ||
path=( | ||
/usr/local/{bin,sbin} | ||
$path | ||
) | ||
|
||
# | ||
# Less | ||
# | ||
|
||
# Set the default Less options. | ||
# Mouse-wheel scrolling has been disabled by -X (disable screen clearing). | ||
# Remove -X and -F (exit if the content fits on one screen) to enable it. | ||
export LESS='-F -g -i -M -R -S -w -X -z-4' | ||
|
||
# Set the Less input preprocessor. | ||
# Try both `lesspipe` and `lesspipe.sh` as either might exist on a system. | ||
if (( $#commands[(i)lesspipe(|.sh)] )); then | ||
export LESSOPEN="| /usr/bin/env $commands[(i)lesspipe(|.sh)] %s 2>&-" | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# Source zsh-autosuggestions | ||
ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE=20 | ||
ZSH_AUTOSUGGEST_USE_ASYNC=yes | ||
source /usr/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh | ||
|
||
# Source zsh-syntax-highlighting | ||
source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh | ||
|
||
# Source aliases | ||
source ~/.dots/config/zsh/aliases.zsh | ||
|
||
# Source ssh-agent | ||
source ~/.dots/config/zsh/ssh-agent.zsh | ||
|
||
# Load virtualenvwrapper | ||
source ~/.local/bin/virtualenvwrapper.sh | ||
|
||
# Load starship (prompt) | ||
eval "$(starship init zsh)" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters