Parcourir la source

Fix fzcd at /, minot refactor

master
Arun Prakash Jana il y a 4 ans
Parent
révision
c01857cddb
Aucune clé connue n'a été trouvée dans la base pour cette signature ID de la clé GPG: A75979F35C080412
2 fichiers modifiés avec 6 ajouts et 5 suppressions
  1. +5
    -1
      plugins/fzcd
  2. +1
    -4
      src/nnn.c

+ 5
- 1
plugins/fzcd Voir le fichier

@@ -32,5 +32,9 @@ if [ -n "$sel" ]; then

# Remove "./" prefix if it exists
sel="${sel#./}"
nnn_cd "$PWD/$sel"
if [ "$PWD" = "/" ]; then
nnn_cd "/$sel"
else
nnn_cd "$PWD/$sel"
fi
fi

+ 1
- 4
src/nnn.c Voir le fichier

@@ -4617,10 +4617,7 @@ static void populate(char *path, char *lastname)

/* Find cur from history */
/* No NULL check for lastname, always points to an array */
if (!*lastname)
move_cursor(0, 0);
else
move_cursor(dentfind(lastname, ndents), 0);
move_cursor(*lastname ? dentfind(lastname, ndents) : 0, 0);

// Force full redraw
last_curscroll = -1;


Chargement…
Annuler
Enregistrer