[PATCH 2/2] bash-completion: fix shellcheck SC2268
Daniel Vetter
daniel.vetter at ffwll.ch
Tue Nov 16 18:14:40 UTC 2021
if [[ "x$1" = "xcd" ]]; then
^---^ SC2268: Avoid x-prefix in comparisons as it no longer serves a purpose.
Signed-off-by: Daniel Vetter <daniel.vetter at intel.com>
---
bash_completion | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/bash_completion b/bash_completion
index 8dcf61ae42d1..e88aa4f98f2d 100644
--- a/bash_completion
+++ b/bash_completion
@@ -2,7 +2,7 @@
dim ()
{
- if [[ "x$1" = "xcd" ]]; then
+ if [[ "$1" = "cd" ]]; then
cd $(cat ~/.dim-last-path) || exit
else
command dim "$@"
--
2.33.0
More information about the dim-tools
mailing list