0
0

style.lua 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116
  1. return {
  2. {
  3. dir = vim.fn.stdpath("config") .. "/custom/jonathandarker",
  4. name = "jonathandarker",
  5. lazy = false,
  6. enabled = true,
  7. config = function()
  8. vim.cmd.colorscheme("jonathandarker")
  9. vim.defer_fn(function()
  10. vim.schedule(function()
  11. vim.cmd.colorscheme("jonathandarker")
  12. end)
  13. end, 100)
  14. vim.opt.list = true
  15. vim.opt.fillchars = "horiz:-," .. "horizup:-," .. "horizdown:-," ..
  16. "vert:¦," .. "verthoriz:¦," ..
  17. "vertleft:¦," .. "vertright:¦," ..
  18. "eob:⠀"
  19. vim.opt.listchars = "extends:›," .. "precedes:‹," ..
  20. "tab:\\ ," .. "nbsp:·," .. "trail:·," ..
  21. "space:·"
  22. end
  23. }, {
  24. dir = vim.fn.stdpath("config") .. "/custom/status-beast",
  25. name = "status-beast",
  26. dependencies = { "lewis6991/gitsigns.nvim", "bit-browser", "command-palette" },
  27. enabled = true,
  28. lazy = false,
  29. config = function()
  30. require("status-beast.highlights").setup()
  31. require("status-beast").setup()
  32. vim.api.nvim_create_autocmd({ "BufEnter" },
  33. {
  34. group = vim.api.nvim_create_augroup('StatusBeast',
  35. { clear = true }),
  36. callback =
  37. require("status-beast").setup
  38. })
  39. vim.diagnostic.config({
  40. virtual_lines = {
  41. current_line = true,
  42. format = function(d)
  43. return "[" .. d.source .. "] " .. d.message
  44. end
  45. },
  46. float = false,
  47. virtual_text = false,
  48. update_in_insert = true
  49. })
  50. local palette = require("command-palette")
  51. palette.add({
  52. {
  53. "Status Beast", "Options for status bars and columns", { {
  54. "Toggle Relnum", "Toggle relative line numbers on/off",
  55. ":setl rnu!" } } }
  56. })
  57. end
  58. }, {
  59. dir = vim.fn.stdpath("config") .. "/custom/jxdash",
  60. name = "jxdash",
  61. dependencies = { "jonathandarker" },
  62. enabled = true,
  63. lazy = false,
  64. config = function()
  65. require("jxdash").setup()
  66. end
  67. }, {
  68. "norcalli/nvim-colorizer.lua",
  69. enabled = true,
  70. lazy = false,
  71. config = function()
  72. require("colorizer").setup({ "*" }, {
  73. mode = "background",
  74. RGB = true,
  75. RRGGBB = true,
  76. RRGGBBAA = true,
  77. names = false,
  78. rgb_fn = false,
  79. hsl_fn = false,
  80. css = false,
  81. css_fn = false
  82. })
  83. end
  84. }, {
  85. "lukas-reineke/virt-column.nvim",
  86. enabled = true,
  87. lazy = false,
  88. config = function()
  89. vim.opt.colorcolumn = tostring(80 + 1)
  90. local cc_group = vim.api.nvim_create_augroup("colorcolumn",
  91. { clear = true })
  92. local filetype_colorcolumn_map = {
  93. python = 88,
  94. kotlin = 100,
  95. julia = 92
  96. }
  97. vim.api.nvim_create_autocmd({ "FileType" }, {
  98. pattern = { "*" },
  99. group = cc_group,
  100. callback = function(event)
  101. local filetype = vim.bo[event.buf].filetype
  102. local colorcolumn = filetype_colorcolumn_map[filetype]
  103. if colorcolumn == nil then
  104. colorcolumn = 80
  105. end
  106. for _, w in pairs(vim.api.nvim_list_wins()) do
  107. if vim.api.nvim_win_get_buf(w) == event.buf then
  108. vim.wo[w].colorcolumn = tostring(colorcolumn + 1)
  109. end
  110. end
  111. end
  112. })
  113. require("virt-column").setup({ char = "⁚" })
  114. end
  115. },
  116. }