Home Explore Blog CI



neovim

23th chunk of `runtime/pack/dist/opt/netrw/doc/netrw.txt`
36f44149e21a852c5bafbc21e9f34ed35436c46b747582c20000000100000fa4
 pressing "D".  Directories must be empty
    first before they can be successfully removed.  If the directory is a
    softlink to a directory, then netrw will make two requests to remove the
    directory before succeeding.  Netrw will ask for confirmation before doing
    the removal(s).  You may select a range of lines with the "V" command
    (visual selection), and then pressing "D".

If files have been marked with |netrw-mf|:   (local marked file list)

    Marked files (and empty directories) will be deleted; again, you'll be
    asked to confirm the deletion before it actually takes place.

A further approach is to delete files which match a pattern.

    * use  :MF pattern  (see |netrw-:MF|); then press "D".

    * use mr (see |netrw-mr|) which will prompt you for pattern.
      This will cause the matching files to be marked.  Then,
      press "D".

Please note that only empty directories may be deleted with the "D" mapping.
Regular files are deleted with |delete()|, too.

The |g:netrw_rm_cmd|, |g:netrw_rmf_cmd|, and |g:netrw_rmdir_cmd| variables are
used to control the attempts to remove remote files and directories.  The
g:netrw_rm_cmd is used with files, and its default value is:

	g:netrw_rm_cmd: ssh HOSTNAME rm

The g:netrw_rmdir_cmd variable is used to support the removal of directories.
Its default value is:

	|g:netrw_rmdir_cmd|: ssh HOSTNAME rmdir

If removing a directory fails with g:netrw_rmdir_cmd, netrw then will attempt
to remove it again using the g:netrw_rmf_cmd variable.  Its default value is:

	|g:netrw_rmf_cmd|: ssh HOSTNAME rm -f

Related topics: |netrw-d|
Associated setting variable: |g:netrw_rm_cmd| |g:netrw_ssh_cmd|


*netrw-explore*  *netrw-hexplore* *netrw-nexplore* *netrw-pexplore*
*netrw-rexplore* *netrw-sexplore* *netrw-texplore* *netrw-vexplore* *netrw-lexplore*
DIRECTORY EXPLORATION COMMANDS  {{{2

     :[N]Explore[!]  [dir]... Explore directory of current file      *:Explore*
     :[N]Hexplore[!] [dir]... Horizontal Split & Explore             *:Hexplore*
     :[N]Lexplore[!] [dir]... Left Explorer Toggle                   *:Lexplore*
     :[N]Sexplore[!] [dir]... Split&Explore current file's directory *:Sexplore*
     :[N]Vexplore[!] [dir]... Vertical   Split & Explore             *:Vexplore*
     :Texplore       [dir]... Tab & Explore                          *:Texplore*
     :Rexplore            ... Return to/from Explorer                *:Rexplore*

     Used with :Explore **/pattern : (also see |netrw-starstar|)
     :Nexplore............. go to next matching file                *:Nexplore*
     :Pexplore............. go to previous matching file            *:Pexplore*

						*netrw-:Explore*
:Explore  will open the local-directory browser on the current file's
          directory (or on directory [dir] if specified).  The window will be
	  split only if the file has been modified and |'hidden'| is not set,
	  otherwise the browsing window will take over that window.  Normally
	  the splitting is taken horizontally.
	  Also see: |netrw-:Rexplore|
:Explore! is like :Explore, but will use vertical splitting.

						*netrw-:Hexplore*
:Hexplore  [dir] does an :Explore with |:belowright| horizontal splitting.
:Hexplore! [dir] does an :Explore with |:aboveleft|  horizontal splitting.

						*netrw-:Lexplore*
:[N]Lexplore [dir] toggles a full height Explorer window on the left hand side
	  of the current tab.  It will open a netrw window on the current
	  directory if [dir] is omitted; a :Lexplore [dir] will show the
	  specified directory in the left-hand side browser display no matter
	  from which window the command is issued.

	  By default, :Lexplore will change an uninitialized |g:netrw_chgwin|
	  to 2; edits will thus preferentially be made in window#2.

	  The [N] specifies a |g:netrw_winsize| just for the new :Lexplore
	  window. That means that
	    if [N] < 0 : use |N| columns for the Lexplore window
	    if [N] = 0 : a normal split is made
	    if [N] > 0 : use N% of the current

Title: Netrw: Deletion Details and Directory Exploration Commands
Summary
This section details the deletion process in Netrw, including handling empty directories, softlinks, and marked files. It also covers the use of remote commands for file and directory removal via 'g:netrw_rm_cmd', 'g:netrw_rmdir_cmd', and 'g:netrw_rmf_cmd'. Furthermore, it describes various directory exploration commands like ':Explore', ':Hexplore', ':Lexplore', ':Sexplore', ':Vexplore', ':Texplore', and ':Rexplore', including how to navigate through matching files with ':Nexplore' and ':Pexplore'.