Skip to content

Commit

Permalink
changed to lsd
Browse files Browse the repository at this point in the history
  • Loading branch information
L-chaCon committed Sep 2, 2024
1 parent 6f717b6 commit d6f003f
Show file tree
Hide file tree
Showing 4 changed files with 197 additions and 4 deletions.
38 changes: 38 additions & 0 deletions iOS/dotfiles/zsh/.config/lsd/colors.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
user: 230
group: 187
permission:
read: Yellow
write: dark_yellow
exec: dark_red
exec-sticky: 5
no-access: 245
octal: 6
acl: dark_cyan
context: cyan
date:
hour-old: 40
day-old: 42
older: 36
size:
none: 245
small: 229
medium: 216
large: 172
inode:
valid: 13
invalid: 245
links:
valid: 13
invalid: 245
tree-edge: 245
git-status:
default: 245
unmodified: 245
ignored: 245
new-in-index: dark_green
new-in-workdir: dark_green
typechange: dark_yellow
deleted: dark_red
renamed: dark_green
modified: dark_yellow
conflicted: dark_red
146 changes: 146 additions & 0 deletions iOS/dotfiles/zsh/.config/lsd/config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,146 @@
# == Classic ==
# This is a shorthand to override some of the options to be backwards compatible
# with `ls`. It affects the "color"->"when", "sorting"->"dir-grouping", "date"
# and "icons"->"when" options.
# Possible values: false, true
classic: false

# == Blocks ==
# Possible values: permission, user, group, context, size, date, name, inode, links, git
blocks:
- permission
- user
- date
- size
- git
- name

# == Color ==
# This has various color options. (Will be expanded in the future.)
color:
# When to colorize the output.
# When "classic" is set, this is set to "never".
# Possible values: never, auto, always
when: auto
# How to colorize the output.
# When "classic" is set, this is set to "no-color".
# Possible values: default, custom
# When "custom" is set, lsd will look in the config directory for `colors.yaml`.
theme: default

# == Date ==
# This specifies the date format for the date column. The freeform format
# accepts a strftime like string.
# When "classic" is set, this is set to "date".
# Possible values: date, locale, relative, '+<date_format>'
# `date_format` will be a `strftime` formatted value. e.g. `date: '+%d %b %y %X'` will give you a date like this: 17 Jun 21 20:14:55
date: relative

# == Dereference ==
# Whether to dereference symbolic links.
# Possible values: false, true
dereference: false

# == Display ==
# What items to display. Do not specify this for the default behavior.
# Possible values: all, almost-all, directory-only
# display: all

# == Icons ==
icons:
# When to use icons.
# When "classic" is set, this is set to "never".
# Possible values: always, auto, never
when: auto
# Which icon theme to use.
# Possible values: fancy, unicode
theme: fancy
# Separator between icon and the name
# Default to 1 space
separator: " "

# == Ignore Globs ==
# A list of globs to ignore when listing.
# ignore-globs:
# - .git

# == Indicators ==
# Whether to add indicator characters to certain listed files.
# Possible values: false, true
indicators: true

# == Layout ==
# Which layout to use. "oneline" might be a bit confusing here and should be
# called "one-per-line". It might be changed in the future.
# Possible values: grid, tree, oneline
layout: oneline

# == Recursion ==
recursion:
# Whether to enable recursion.
# Possible values: false, true
enabled: false
# How deep the recursion should go. This has to be a positive integer. Leave
# it unspecified for (virtually) infinite.
# depth: 3

# == Size ==
# Specifies the format of the size column.
# Possible values: default, short, bytes
size: default

# == Permission ==
# Specify the format of the permission column
# Possible value: rwx, octal, attributes (windows only), disable
# permission: rwx

# == Sorting ==
sorting:
# Specify what to sort by.
# Possible values: extension, name, time, size, version
column: name
# Whether to reverse the sorting.
# Possible values: false, true
reverse: false
# Whether to group directories together and where.
# When "classic" is set, this is set to "none".
# Possible values: first, last, none
dir-grouping: first

# == No Symlink ==
# Whether to omit showing symlink targets
# Possible values: false, true
no-symlink: false

# == Total size ==
# Whether to display the total size of directories.
# Possible values: false, true
total-size: false

# == Hyperlink ==
# Attach hyperlink to filenames
# Possible values: always, auto, never
hyperlink: never

# == Symlink arrow ==
# Specifies how the symlink arrow display, chars in both ascii and utf8
symlink-arrow:

# == Header ==
# Whether to display block headers.
# Possible values: false, true
header: false

# == Literal ==
# Whether to show quotes on filenames.
# Possible values: false, true
literal: false

# == Truncate owner ==
# How to truncate the username and group names for a file if they exceed a certain
# number of characters.
truncate-owner:
# Number of characters to keep. By default, no truncation is done (empty value).
after:
# String to be appended to a name if truncated.
marker: ""
14 changes: 11 additions & 3 deletions iOS/dotfiles/zsh/.zshrc
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ CASE_SENSITIVE="true"
# User configuration
plugins=(git zsh-autosuggestions zsh-syntax-highlighting fzf)
source $ZSH/oh-my-zsh.sh
set -o vi
# MAN & HELP
export MANPATH="/usr/local/man:$MANPATH"
export MANPAGER="sh -c 'col -bx | bat -l man -p'"
Expand All @@ -16,8 +17,11 @@ alias -g -- --help='--help 2>&1 | bat --language=help --style=plain'
# USER
export LANG=en_GB.UTF-8
export PAGER="bat"
# GO Path
export PATH="/Users/artlogic/go/bin:$PATH"
# ALIAS
alias rm="rm -iv"
alias sve="source .venv/bin/activate"
# ---- FZF -----
# Set up fzf key bindings and fuzzy completion
eval "$(fzf --zsh)"
Expand Down Expand Up @@ -46,16 +50,20 @@ _fzf_comprun() {
local command=$1
shift
case "$command" in
cd) fzf --preview 'eza --tree --color=always {} | head -200' "$@" ;;
cd) fzf --preview 'lsd --tree {} | head -200' "$@" ;;
export|unset) fzf --preview "eval 'echo $'{}" "$@" ;;
ssh) fzf --preview 'dig {}' "$@" ;;
*) fzf --preview "bat -n --color=always --line-range :500 {}" "$@" ;;
esac
}
# ----- Bat (better cat) -----
export BAT_THEME="Coldark-Dark"
# ---- Eza (better ls) -----
alias ls="eza --color=always --long --git --no-user --icons=always"
# ---- LSD (better ls) -----
alias ls="lsd"
alias l='ls -l'
alias la='ls -a'
alias lla='ls -la'
alias lt='ls --tree'
# ---- Tmux Sessionizer (based on ThePrimagen)
export FZF_SEARCH_FOLDERS="$HOME/Desktop/Kun/Personal:$HOME/Desktop/Kun/3.artlogic:$HOME"
bindkey -s "^ " 'source ~/.local/scripts/tmux-sessionizer\n'
Expand Down
3 changes: 2 additions & 1 deletion iOS/tasks/zsh.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,11 @@
- fd
- bat
- git-delta
- eza
- lsd
- tldr
- zoxide
- starship
- viu
tags:
- install
- zsh
Expand Down

0 comments on commit d6f003f

Please sign in to comment.