You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

159 lines
5.6 KiB

  1. -- Automatically generated packer.nvim plugin loader code
  2. if vim.api.nvim_call_function('has', {'nvim-0.5'}) ~= 1 then
  3. vim.api.nvim_command('echohl WarningMsg | echom "Invalid Neovim version for packer.nvim! | echohl None"')
  4. return
  5. end
  6. vim.api.nvim_command('packadd packer.nvim')
  7. local no_errors, error_msg = pcall(function()
  8. local time
  9. local profile_info
  10. local should_profile = false
  11. if should_profile then
  12. local hrtime = vim.loop.hrtime
  13. profile_info = {}
  14. time = function(chunk, start)
  15. if start then
  16. profile_info[chunk] = hrtime()
  17. else
  18. profile_info[chunk] = (hrtime() - profile_info[chunk]) / 1e6
  19. end
  20. end
  21. else
  22. time = function(chunk, start) end
  23. end
  24. local function save_profiles(threshold)
  25. local sorted_times = {}
  26. for chunk_name, time_taken in pairs(profile_info) do
  27. sorted_times[#sorted_times + 1] = {chunk_name, time_taken}
  28. end
  29. table.sort(sorted_times, function(a, b) return a[2] > b[2] end)
  30. local results = {}
  31. for i, elem in ipairs(sorted_times) do
  32. if not threshold or threshold and elem[2] > threshold then
  33. results[i] = elem[1] .. ' took ' .. elem[2] .. 'ms'
  34. end
  35. end
  36. _G._packer = _G._packer or {}
  37. _G._packer.profile_output = results
  38. end
  39. time([[Luarocks path setup]], true)
  40. local package_path_str = "/home/tovi/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?.lua;/home/tovi/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?/init.lua;/home/tovi/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?.lua;/home/tovi/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?/init.lua"
  41. local install_cpath_pattern = "/home/tovi/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/lua/5.1/?.so"
  42. if not string.find(package.path, package_path_str, 1, true) then
  43. package.path = package.path .. ';' .. package_path_str
  44. end
  45. if not string.find(package.cpath, install_cpath_pattern, 1, true) then
  46. package.cpath = package.cpath .. ';' .. install_cpath_pattern
  47. end
  48. time([[Luarocks path setup]], false)
  49. time([[try_loadstring definition]], true)
  50. local function try_loadstring(s, component, name)
  51. local success, result = pcall(loadstring(s), name, _G.packer_plugins[name])
  52. if not success then
  53. vim.schedule(function()
  54. vim.api.nvim_notify('packer.nvim: Error running ' .. component .. ' for ' .. name .. ': ' .. result, vim.log.levels.ERROR, {})
  55. end)
  56. end
  57. return result
  58. end
  59. time([[try_loadstring definition]], false)
  60. time([[Defining packer_plugins]], true)
  61. _G.packer_plugins = {
  62. ["coc.nvim"] = {
  63. loaded = true,
  64. path = "/home/tovi/.local/share/nvim/site/pack/packer/start/coc.nvim",
  65. url = "https://github.com/neoclide/coc.nvim"
  66. },
  67. ["dart-vim-plugin"] = {
  68. loaded = true,
  69. path = "/home/tovi/.local/share/nvim/site/pack/packer/start/dart-vim-plugin",
  70. url = "https://github.com/dart-lang/dart-vim-plugin"
  71. },
  72. ["git-blame.nvim"] = {
  73. loaded = true,
  74. path = "/home/tovi/.local/share/nvim/site/pack/packer/start/git-blame.nvim",
  75. url = "https://github.com/f-person/git-blame.nvim"
  76. },
  77. gruvbox = {
  78. loaded = true,
  79. path = "/home/tovi/.local/share/nvim/site/pack/packer/start/gruvbox",
  80. url = "https://github.com/gruvbox-community/gruvbox"
  81. },
  82. ["packer.nvim"] = {
  83. loaded = true,
  84. path = "/home/tovi/.local/share/nvim/site/pack/packer/start/packer.nvim",
  85. url = "https://github.com/wbthomason/packer.nvim"
  86. },
  87. ["php-doc-modded"] = {
  88. loaded = true,
  89. path = "/home/tovi/.local/share/nvim/site/pack/packer/start/php-doc-modded",
  90. url = "https://github.com/Rican7/php-doc-modded"
  91. },
  92. ["plenary.nvim"] = {
  93. loaded = true,
  94. path = "/home/tovi/.local/share/nvim/site/pack/packer/start/plenary.nvim",
  95. url = "https://github.com/nvim-lua/plenary.nvim"
  96. },
  97. ["popup.nvim"] = {
  98. loaded = true,
  99. path = "/home/tovi/.local/share/nvim/site/pack/packer/start/popup.nvim",
  100. url = "https://github.com/nvim-lua/popup.nvim"
  101. },
  102. ["telescope-fzy-native.nvim"] = {
  103. loaded = true,
  104. path = "/home/tovi/.local/share/nvim/site/pack/packer/start/telescope-fzy-native.nvim",
  105. url = "https://github.com/nvim-telescope/telescope-fzy-native.nvim"
  106. },
  107. ["telescope.nvim"] = {
  108. loaded = true,
  109. path = "/home/tovi/.local/share/nvim/site/pack/packer/start/telescope.nvim",
  110. url = "https://github.com/nvim-telescope/telescope.nvim"
  111. },
  112. ["tmux.nvim"] = {
  113. loaded = true,
  114. path = "/home/tovi/.local/share/nvim/site/pack/packer/start/tmux.nvim",
  115. url = "https://github.com/aserowy/tmux.nvim"
  116. },
  117. ["vim-go"] = {
  118. commands = { "GoUpdateBinaries" },
  119. loaded = false,
  120. needs_bufread = true,
  121. only_cond = false,
  122. path = "/home/tovi/.local/share/nvim/site/pack/packer/opt/vim-go",
  123. url = "https://github.com/fatih/vim-go"
  124. },
  125. ["vim-gofmt"] = {
  126. commands = { "GoUpdateBinaries" },
  127. loaded = false,
  128. needs_bufread = true,
  129. only_cond = false,
  130. path = "/home/tovi/.local/share/nvim/site/pack/packer/opt/vim-gofmt",
  131. url = "https://github.com/darrikonn/vim-gofmt"
  132. }
  133. }
  134. time([[Defining packer_plugins]], false)
  135. -- Command lazy-loads
  136. time([[Defining lazy-load commands]], true)
  137. pcall(vim.cmd, [[command -nargs=* -range -bang -complete=file GoUpdateBinaries lua require("packer.load")({'vim-go', 'vim-gofmt'}, { cmd = "GoUpdateBinaries", l1 = <line1>, l2 = <line2>, bang = <q-bang>, args = <q-args>, mods = "<mods>" }, _G.packer_plugins)]])
  138. time([[Defining lazy-load commands]], false)
  139. if should_profile then save_profiles() end
  140. end)
  141. if not no_errors then
  142. error_msg = error_msg:gsub('"', '\\"')
  143. vim.api.nvim_command('echohl ErrorMsg | echom "Error in packer_compiled: '..error_msg..'" | echom "Please check your config for correctness" | echohl None')
  144. end