Use ${PWD} instead of $(pwd)
Don't subshell when there's a shell parameter for it.
This commit is contained in:
2
themes/powerturk/powerturk.theme.bash
Normal file → Executable file
2
themes/powerturk/powerturk.theme.bash
Normal file → Executable file
@@ -43,7 +43,7 @@ _swd(){
|
||||
begin="" # The unshortened beginning of the path.
|
||||
shortbegin="" # The shortened beginning of the path.
|
||||
current="" # The section of the path we're currently working on.
|
||||
end="${2:-$(pwd)}/" # The unmodified rest of the path.
|
||||
end="${2:-${PWD}}/" # The unmodified rest of the path.
|
||||
|
||||
if [[ "$end" =~ "$HOME" ]]; then
|
||||
INHOME=1
|
||||
|
||||
Reference in New Issue
Block a user