Skip to content

Commit

Permalink
build: ➖ reduce dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
ivaquero committed Nov 20, 2023
1 parent dfcbb02 commit 53419bb
Show file tree
Hide file tree
Showing 9 changed files with 20 additions and 29 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,11 +80,11 @@ Oxidizer is originally designed for **non-administrator** users. It saves your t
- [x] Use [lsd](https://github.com/Peltoche/lsd) instead of `ls`
- non-coreutils
- [x] Use [fd](https://github.com/sharkdp/fd) instead of `find`
- [x] Use [hyperfine](https://github.com/sharkdp/hyperfine) instead of `time`
- [x] Use [ripgrep](https://github.com/BurntSushi/ripgrep) instead of `grep` (only required on Windows)
- [x] Use [tealdeer](https://github.com/dbrgn/tealdeer) instead of `tldr` or `man`
- [x] Use [zoxide](https://github.com/ajeetdsouza/zoxide) instead of `cd` or `z`
- [ ] Use [dust](https://github.com/bootandy/dust) instead of `du`
- [ ] Use [hyperfine](https://github.com/sharkdp/hyperfine) instead of `time`
- [ ] Use [procs](https://github.com/dalance/procs) instead of `ps`
- [ ] Use [starship](https://github.com/starship/starship) instead of `powerline10k` or `ohmyposh`
- [ ] Use [tokei](https://github.com/XAMPPRocky/tokei) instead of `cloc`
Expand Down
2 changes: 1 addition & 1 deletion README_CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,11 @@ Oxidizer 起初主要为非管理员用户设计,用于快速搭建跨平台
- [x] 使用 [lsd](https://github.com/Peltoche/lsd) 替换 `ls`
- non-coreutils
- [x] 使用 [fd](https://github.com/sharkdp/fd) 替换 `find`
- [x] 使用 [hyperfine](https://github.com/sharkdp/hyperfine) 替换 `time`
- [x] 使用 [ripgrep](https://github.com/BurntSushi/ripgrep) 替换 `grep`(仅 Windows)
- [x] 使用 [tealdeer](https://github.com/dbrgn/tealdeer) 替换 `tldr``man`
- [x] 使用 [zoxide](https://github.com/ajeetdsouza/zoxide) 替换 `cd``z`
- [ ] 使用 [dust](https://github.com/bootandy/dust) 替换 `du`
- [ ] 使用 [hyperfine](https://github.com/sharkdp/hyperfine) 替换 `time`
- [ ] 使用 [procs](https://github.com/dalance/procs) 替换 `ps`
- [ ] 使用 [starship](https://github.com/starship/starship) 替换 `powerline10k``ohmyposh`
- [ ] 使用 [tokei](https://github.com/XAMPPRocky/tokei) 替换 `cloc`
Expand Down
6 changes: 3 additions & 3 deletions defaults.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -148,14 +148,14 @@ function rr { rm -rf $args }
function c { clear }

# tools
function man { tldr $args }
function hf { hyperfine $args }
# function man { tldr $args }
# function hf { hyperfine $args }

##########################################################
# powershell
##########################################################

function tt { hyperfine --warmup 3 --shell powershell '. $PROFILE' }
# function tt { hyperfine --warmup 3 --shell powershell '. $PROFILE' }

##########################################################
# startup & daily commands
Expand Down
30 changes: 15 additions & 15 deletions defaults.sh
Original file line number Diff line number Diff line change
Expand Up @@ -186,26 +186,14 @@ alias shls="cat ${SHELLS}"
alias quit="killall -9"

# tools
alias man="tldr"
alias hf="hyperfine"
alias zz="z -"
# alias man="tldr"
# alias hf="hyperfine"
# alias zz="z -"

##########################################################
# shell
##########################################################

# test profile loading time
tt() {
case ${SHELL} in
*zsh)
hyperfine --warmup 3 --shell zsh "source ${OX_ELEMENT[zs]}"
;;
*bash)
hyperfine --warmup 3 --shell bash "source ${OX_ELEMENT[bs]}"
;;
esac
}

# clean history
ccc() {
case ${SHELL} in
Expand Down Expand Up @@ -235,6 +223,18 @@ case ${SHELL} in
;;
esac

# test profile loading time
# tt() {
# case ${SHELL} in
# *zsh)
# hyperfine --warmup 3 --shell zsh "source ${OX_ELEMENT[zs]}"
# ;;
# *bash)
# hyperfine --warmup 3 --shell bash "source ${OX_ELEMENT[bs]}"
# ;;
# esac
# }

##########################################################
# startup commands
##########################################################
Expand Down
1 change: 0 additions & 1 deletion defaults/Brewfile.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
bat
fd
gitui
hyperfine
lsd
ouch
tealdeer
Expand Down
1 change: 0 additions & 1 deletion defaults/Scoopfile.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
bat
fd
gitui
hyperfine
lsd
ouch
tealdeer
Expand Down
2 changes: 0 additions & 2 deletions install.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,7 @@ $pkgs = cat "$env:OXIDIZER\defaults\Scoopfile.txt"

ForEach ( $pkg in $pkgs ) {
Switch ( $pkg ) {
bottom { $cmd = 'btm' }
ripgrep { $cmd = 'rg' }
tealdeer { $cmd = 'tldr' }
zoxide { $cmd = 'z' }
Default { $cmd = $pkg }
}
Expand Down
2 changes: 0 additions & 2 deletions oxidizer.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -114,9 +114,7 @@ function iiox {
$pkgs = cat "$env:OXIDIZER\defaults\Scoopfile.txt"
ForEach ( $pkg in $pkgs ) {
Switch ( $pkg ) {
bottom { $cmd = 'btm' }
ripgrep { $cmd = 'rg' }
tealdeer { $cmd = 'tldr' }
zoxide { $cmd = 'z' }
Default { $cmd = $pkg }
}
Expand Down
3 changes: 0 additions & 3 deletions oxidizer.sh
Original file line number Diff line number Diff line change
Expand Up @@ -136,9 +136,6 @@ iiox() {
printf "📦 Installing Required packages...\n"
while read -r pkg <"${OXIDIZER}"/defaults/Brewfile.txt; do
case $pkg in
tealdear)
cmd='tldr'
;;
zoxide)
cmd='z'
;;
Expand Down

0 comments on commit 53419bb

Please sign in to comment.