]> git.notmuchmail.org Git - notmuch/commitdiff
Convert notmuch-vim to Vim addon policy 2.0
authorJames McCoy <jamessan@debian.org>
Sat, 3 Aug 2024 18:56:06 +0000 (14:56 -0400)
committerDavid Bremner <david@tethera.net>
Mon, 5 Aug 2024 09:59:43 +0000 (06:59 -0300)
The new Vim addon policy relies on Vim's native package functionality,
rather than the Debian-specific vim-addons tool.  This allows the addon
to be immediately available when the package is installed, rather than
requiring extra setup by the user.

* Install notmuch-vim to its own /usr/share/notmuch-vim directory, so
  the files are self-contained.
* Remove vim-addon-manager from notmuch-vim Depends
* Add ${vim-addon:Depends} to notmuch-vim Depends to ensure it has the
  required relationships on Vim/Neovim.
* Build-Depend on dh-sequence-vim-addon to automatically setup the
  required symlinks for Vim and Neovim to see the addon.

Signed-off-by: James McCoy <jamessan@debian.org>
debian/control
debian/notmuch-vim.dirs [deleted file]
debian/notmuch-vim.install
debian/notmuch-vim.neovim-addon [new symlink]
debian/notmuch-vim.vim-addon [new file with mode: 0644]
debian/rules

index 4fded909a03ca5d4910c2cc8f1fee4f03795ebbe..77096b8560f291f1166ad83272a8eb72265fa9bb 100644 (file)
@@ -14,6 +14,7 @@ Build-Depends: dpkg-dev (>= 1.22.5),
  debhelper-compat (= 13),
  dh-elpa (>= 1.3),
  dh-python,
+ dh-sequence-vim-addon,
  desktop-file-utils,
  doxygen,
  dpkg-dev (>= 1.17.14),
@@ -211,9 +212,9 @@ Replaces:
 Depends:
  notmuch,
  ruby-notmuch,
- vim-addon-manager,
  vim-ruby,
  ${misc:Depends},
+ ${vim-addon:Depends},
 Recommends:
  ruby-mail,
 Description: thread-based email index, search and tagging (vim interface)
diff --git a/debian/notmuch-vim.dirs b/debian/notmuch-vim.dirs
deleted file mode 100644 (file)
index 2b53131..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-usr/share/vim/addons/doc
-usr/share/vim/addons/plugin
-usr/share/vim/addons/syntax
-usr/share/vim/registry
index cf8987385a097665fdb84df8aa2f1eb8e2d724f4..08096d37ef958c0cae4acb5f2de8a8742454bc0d 100644 (file)
@@ -1,4 +1 @@
-vim/notmuch.txt usr/share/vim/addons/doc
-vim/notmuch.vim usr/share/vim/addons/plugin
-vim/notmuch.yaml usr/share/vim/registry
-vim/syntax/notmuch-*.vim usr/share/vim/addons/syntax
+/usr/share/notmuch-vim
diff --git a/debian/notmuch-vim.neovim-addon b/debian/notmuch-vim.neovim-addon
new file mode 120000 (symlink)
index 0000000..a576db7
--- /dev/null
@@ -0,0 +1 @@
+notmuch-vim.vim-addon
\ No newline at end of file
diff --git a/debian/notmuch-vim.vim-addon b/debian/notmuch-vim.vim-addon
new file mode 100644 (file)
index 0000000..9c23ba1
--- /dev/null
@@ -0,0 +1 @@
+/usr/share/notmuch-vim notmuch
index a77ffa152daefd3ca8a611121cc3509a9e5c341d..ecf09abc3514017b37fbe8f433e8d95cfcc3779b 100755 (executable)
@@ -37,4 +37,5 @@ override_dh_auto_install:
        PYBUILD_NAME=notmuch dh_auto_install --buildsystem=pybuild --sourcedirectory bindings/python
        PYBUILD_NAME=notmuch2 dh_auto_install --buildsystem=pybuild --sourcedirectory bindings/python-cffi
        $(MAKE) -C contrib/notmuch-mutt DESTDIR=$(CURDIR)/debian/tmp install
+       $(MAKE) -C vim prefix=/usr/share/notmuch-vim DESTDIR=$(CURDIR)/debian/tmp install
        dh_auto_install --sourcedirectory bindings/ruby