From 1c91dde68b6226bff035986ee7d8685b87cdf020 Mon Sep 17 00:00:00 2001 From: Klesh Wong Date: Sat, 6 Mar 2021 21:06:27 +0800 Subject: [PATCH 1/2] [misc] add ~/go/bin to PATH --- cli/fish/config.fish | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cli/fish/config.fish b/cli/fish/config.fish index cfb971b..5d3cd59 100644 --- a/cli/fish/config.fish +++ b/cli/fish/config.fish @@ -53,7 +53,7 @@ if status is-interactive alias dt='date "+%Y%m%d-%H%M%S"' # === PATH and file sourcing - append_paths ~/bin ~/.local/bin ~/.yarn/bin ~/dotfiles/bin ~/dotfiles/devops/bin + append_paths ~/go/bin ~/bin ~/.local/bin ~/.yarn/bin ~/dotfiles/bin ~/dotfiles/devops/bin source_files /usr/share/autojump/autojump.fish /usr/local/share/autojump/autojump.fish \ ~/.jabba/jabba.fish \ ~/.profile.fish From 6324cfd7b024d1a4e36b20d5f0c295e4abc694dd Mon Sep 17 00:00:00 2001 From: Klesh Wong Date: Sun, 21 Mar 2021 18:09:58 +0800 Subject: [PATCH 2/2] [misc] lf for win --- cli/lf/lfrc.win | 5 +++++ win/profile.ps1 | 10 ++++++++++ 2 files changed, 15 insertions(+) diff --git a/cli/lf/lfrc.win b/cli/lf/lfrc.win index 897eb3f..8831d89 100644 --- a/cli/lf/lfrc.win +++ b/cli/lf/lfrc.win @@ -1,5 +1,10 @@ +set icons +set drawbox cmd mkdir %mkdir "$@" cmd fp %powershell -NoProfile -Command Set-Clipboard $env:f cmd fn %powershell -NoProfile -Command Set-Clipboard (Split-Path -Leaf ($env:f -replace '"','')) + + +map rename diff --git a/win/profile.ps1 b/win/profile.ps1 index 6fd1433..4cde92e 100644 --- a/win/profile.ps1 +++ b/win/profile.ps1 @@ -113,3 +113,13 @@ function pass-edit { Remove-Item $tmpfile.FullName -Force } } + +function f { + [Cmdletbinding()] + + $tmpfile = New-TemporaryFile + lf -last-dir-path $tmpfile + $lastdir = Get-Content $tmpfile + Remove-Item $tmpfile + cd $lastdir +}