{"id":21475918,"url":"https://github.com/roginfarrer/vim-dirvish-dovish","last_synced_at":"2025-06-24T07:39:24.039Z","repository":{"id":38086895,"uuid":"285466594","full_name":"roginfarrer/vim-dirvish-dovish","owner":"roginfarrer","description":"File manipulation commands for vim-dirvish","archived":false,"fork":false,"pushed_at":"2022-06-10T12:51:14.000Z","size":24,"stargazers_count":36,"open_issues_count":3,"forks_count":4,"subscribers_count":1,"default_branch":"main","last_synced_at":"2023-02-27T09:23:13.120Z","etag":null,"topics":["file-management","neovim","vim","vim-dirvish"],"latest_commit_sha":null,"homepage":"","language":"Vim script","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/roginfarrer.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-08-06T03:45:32.000Z","updated_at":"2023-01-07T17:00:13.000Z","dependencies_parsed_at":"2022-07-12T00:31:03.195Z","dependency_job_id":null,"html_url":"https://github.com/roginfarrer/vim-dirvish-dovish","commit_stats":null,"previous_names":[],"tags_count":null,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/roginfarrer%2Fvim-dirvish-dovish","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/roginfarrer%2Fvim-dirvish-dovish/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/roginfarrer%2Fvim-dirvish-dovish/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/roginfarrer%2Fvim-dirvish-dovish/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/roginfarrer","download_url":"https://codeload.github.com/roginfarrer/vim-dirvish-dovish/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":226033272,"owners_count":17563125,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["file-management","neovim","vim","vim-dirvish"],"created_at":"2024-11-23T10:46:30.861Z","updated_at":"2024-11-23T10:46:31.683Z","avatar_url":"https://github.com/roginfarrer.png","language":"Vim script","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🧰 vim-dirvish-dovish\n\n\u003e The file manipulation commands for [vim-dirvish][dirvish] that you've always wanted\n\nHave only tested on MacOS and Neovim, but it should work with Vim.\n\n## Installation \u0026 Requirements\n\nYou'll need:\n\n- [dirvish.vim][dirvish]\n- A CLI that provides a `trash` command, such as [trash](https://formulae.brew.sh/formula/trash) or [trash-cli](https://github.com/sindresorhus/trash-cli)\n\nThen install with your favorite package manager:\n\n```vim\nPlug 'roginfarrer/vim-dirvish-dovish', {'branch': 'main'}\n```\n\n## Mappings\n\n| Function                                | Default | Key                               |\n| --------------------------------------- | ------- | --------------------------------- |\n| Create file                             | `a`     | `\u003cPlug\u003e(dovish_create_file)`      |\n| Create directory                        | `A`     | `\u003cPlug\u003e(dovish_create_directory)` |\n| Delete under cursor                     | `dd`    | `\u003cPlug\u003e(dovish_delete)`           |\n| Rename under cursor                     | `r`     | `\u003cPlug\u003e(dovish_rename)`           |\n| Yank under cursor (or visual selection) | `yy`    | `\u003cPlug\u003e(dovish_yank)`             |\n| Copy file to current directory          | `pp`    | `\u003cPlug\u003e(dovish_copy)`             |\n| Move file to current directory          | `PP`    | `\u003cPlug\u003e(dovish_move)`             |\n\nYou can unmap all of the maps above and set your own (mine are below). Add this to `ftplugin/dirvish.vim`:\n\n```vim\n\" unmap all default mappings\nlet g:dirvish_dovish_map_keys = 0\n\n\" unmap dirvish default\nunmap \u003cbuffer\u003e p\n\n\" Your preferred mappings\nnmap \u003csilent\u003e\u003cbuffer\u003e i \u003cPlug\u003e(dovish_create_file)\nnmap \u003csilent\u003e\u003cbuffer\u003e I \u003cPlug\u003e(dovish_create_directory)\nnmap \u003csilent\u003e\u003cbuffer\u003e dd \u003cPlug\u003e(dovish_delete)\nnmap \u003csilent\u003e\u003cbuffer\u003e r \u003cPlug\u003e(dovish_rename)\nnmap \u003csilent\u003e\u003cbuffer\u003e yy \u003cPlug\u003e(dovish_yank)\nxmap \u003csilent\u003e\u003cbuffer\u003e yy \u003cPlug\u003e(dovish_yank)\nnmap \u003csilent\u003e\u003cbuffer\u003e p \u003cPlug\u003e(dovish_copy)\nnmap \u003csilent\u003e\u003cbuffer\u003e P \u003cPlug\u003e(dovish_move)\n```\n\n## Customize Commands\n\nMost file operations can be customized. Below are the defaults:\n\n```vim\n\" Used for \u003cPlug\u003e(dovish_yank)\nfunction! g:DovishCopyFile(target, destination) abort\n  return 'cp ' . a:target . ' ' . a:destination\nendfunction\n\n\" Used for \u003cPlug\u003e(dovish_yank)\nfunction! g:DovishCopyDirectory(target, destination) abort\n  return 'cp -r' . a:target . ' ' . a:destination\nendfunction\n\n\" Used for \u003cPlug\u003e(dovish_move)\nfunction! g:DovishMove(target, destination) abort\n  return 'mv ' . a:target . ' ' . a:destination\nendfunction\n\n\" Used for \u003cPlug\u003e(dovish_delete)\nfunction! g:DovishDelete(target) abort\n  return 'trash ' . a:target\nendfunction\n\n\" Used for \u003cPlug\u003e(dovish_rename)\nfunction! g:DovishRename(target, destination) abort\n  return 'mv ' . a:target . ' ' . a:destination\nendfunction\n```\n\n[dirvish]: https://github.com/justinmk/vim-dirvish\n\n## Credit\n\nBig shout out to [Melandel](https://github.com/Melandel) for laying the [foundation](https://github.com/Melandel/desktop/blob/c323969e4bd48dda6dbceada3a7afe8bacdda0f5/setup/my_vimrc.vim#L976-L1147) for this plugin!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Froginfarrer%2Fvim-dirvish-dovish","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Froginfarrer%2Fvim-dirvish-dovish","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Froginfarrer%2Fvim-dirvish-dovish/lists"}