pspec.vim 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. if &compatible || v:version < 603
  2. finish
  3. endif
  4. fun! MakeNewPSPEC()
  5. set nopaste
  6. 0 put = '<?xml version=\"1.0\" ?>'
  7. put = '<!DOCTYPE INARY SYSTEM \"https://raw.githubusercontent.com/Zaryob/inary/master/inary-spec.dtd\">'
  8. put = '<INARY>'
  9. put = ' <Source>'
  10. put = ' <Name></Name>'
  11. put = ' <Homepage>http://</Homepage>'
  12. put = ' <Packager>'
  13. put = ' <Name></Name>'
  14. put = ' <Email></Email>'
  15. put = ' </Packager>'
  16. put = ' <License>GPLv2</License>'
  17. put = ' <Icon></Icon>'
  18. put = ' <IsA></IsA>'
  19. put = ' <Summary></Summary>'
  20. put = ' <Description></Description>'
  21. put = ' <Archive sha1sum=\"\" type=\"\">http://</Archive>'
  22. put = ' <BuildDependencies>'
  23. put = ' <Dependency></Dependency>'
  24. put = ' </BuildDependencies>'
  25. put = ' <Patches>'
  26. put = ' <Patch level=\"\"></Patch>'
  27. put = ' </Patches>'
  28. put = ' </Source>'
  29. put = ''
  30. put = ' <Package>'
  31. put = ' <Name></Name>'
  32. put = ' <RuntimeDependencies>'
  33. put = ' <Dependency versionFrom=\"\"></Dependency>'
  34. put = ' </RuntimeDependencies>'
  35. put = ' <Files>'
  36. put = ' <Path fileType=\"config\">/etc</Path>'
  37. put = ' <Path fileType=\"executable\">/usr/bin</Path>'
  38. put = ' <Path fileType=\"header\">/usr/include</Path>'
  39. put = ' <Path fileType=\"library\">/usr/lib</Path>'
  40. put = ' <Path fileType=\"localedata\">/usr/share/locale</Path>'
  41. put = ' <Path fileType=\"man\">/usr/share/man</Path>'
  42. put = ' <Path fileType=\"doc\">/usr/share/doc</Path>'
  43. put = ' <Path fileType=\"data\">/usr/share</Path>'
  44. put = ' </Files>'
  45. put = ' <AdditionalFiles>'
  46. put = ' <AdditionalFile owner=\"root\" permission=\"0644\" target=\"\"></AdditionalFile>'
  47. put = ' </AdditionalFiles>'
  48. put = ' <Provides>'
  49. put = ' <SCOM script=\"\"></SCOM>'
  50. put = ' </Provides>'
  51. put = ' </Package>'
  52. put = ''
  53. put = ' <History>'
  54. put = ' <Update release=\"1\">'
  55. put = ' <Date>YYYY-MM-DD</Date>'
  56. put = ' <Version></Version>'
  57. put = ' <Comment>First release.</Comment>'
  58. put = ' <Name></Name>'
  59. put = ' <Email></Email>'
  60. put = ' </Update>'
  61. put = ' </History>'
  62. put = '</INARY>'
  63. 14
  64. endfun
  65. com! -nargs=0 NewPSPEC call MakeNewPSPEC()
  66. augroup NewPSPEC
  67. au!
  68. autocmd BufNewFile pspec.xml call MakeNewPSPEC()
  69. augroup END
  70. " vim: set et foldmethod=marker : "