diff options
| author | srdusr <trevorgray@srdusr.com> | 2023-11-15 11:04:51 +0200 |
|---|---|---|
| committer | srdusr <trevorgray@srdusr.com> | 2023-11-15 11:04:51 +0200 |
| commit | 6775aea79daae171bf94740335330549c24fabbc (patch) | |
| tree | 2032455dbe11edd4e5b504ecb2a4a7bb6c65482c /.config/nvim/lua/plugins/dashboard.lua | |
| parent | b689c502591b7e636a45fca155a77ad16027b286 (diff) | |
| parent | 95b766869be7958967d8cab3463753970168ae33 (diff) | |
| download | dotfiles-6775aea79daae171bf94740335330549c24fabbc.tar.gz dotfiles-6775aea79daae171bf94740335330549c24fabbc.zip | |
Merge commit '95b766869be7958967d8cab3463753970168ae33'
Diffstat (limited to '.config/nvim/lua/plugins/dashboard.lua')
| -rw-r--r-- | .config/nvim/lua/plugins/dashboard.lua | 59 |
1 files changed, 34 insertions, 25 deletions
diff --git a/.config/nvim/lua/plugins/dashboard.lua b/.config/nvim/lua/plugins/dashboard.lua index e25d536..f02242c 100644 --- a/.config/nvim/lua/plugins/dashboard.lua +++ b/.config/nvim/lua/plugins/dashboard.lua @@ -1,4 +1,11 @@ -local db = require("dashboard") +local db = require('dashboard') +local messages = require('plugins.messages') + +function GetRandomMessage() + -- Get a random index from the messages array + local randomIndex = math.random(1, #messages) + return messages[randomIndex] +end --vim.api.nvim_create_autocmd("VimEnter", { -- callback = function() @@ -10,9 +17,9 @@ local db = require("dashboard") --}) db.setup({ - theme = "hyper", + theme = 'hyper', config = { - mru = { limit = 10, label = "" }, + mru = { limit = 10, label = '' }, project = { limit = 10 }, header = { [[ ███╗ ██╗ ███████╗ ██████╗ ██╗ ██╗ ██╗ ███╗ ███╗]], @@ -24,45 +31,47 @@ db.setup({ }, disable_move = false, shortcut = { - { desc = " Plugins", group = "Number", action = "PackerStatus", key = "p" }, + { desc = ' Plugins', group = 'Number', action = 'PackerStatus', key = 'p' }, --{ desc = " Plugins", group = "@property", action = "PackerStatus", key = "p" }, { - desc = " Files", - group = "Number", + desc = ' Files', + group = 'Number', --group = "Label", - action = "Telescope find_files", - key = "f", + action = 'Telescope find_files', + key = 'f', }, { - desc = " Text", - group = "Number", + desc = ' Text', + group = 'Number', --group = "Label", - action = "enew", - key = "t", + action = 'enew', + key = 't', }, { - desc = " Grep", - group = "Number", + desc = ' Grep', + group = 'Number', --group = "Label", - action = "Telescope live_grep", - key = "g", + action = 'Telescope live_grep', + key = 'g', }, { - desc = " Scheme", - group = "Number", + desc = ' Scheme', + group = 'Number', --group = "Label", - action = "Telescope colorscheme", - key = "s", + action = 'Telescope colorscheme', + key = 's', }, { - desc = " Config", - group = "Number", + desc = ' Config', + group = 'Number', --group = "Label", - action = ":edit ~/.config/nvim/init.lua", - key = "c", + action = ':edit ~/.config/nvim/init.lua', + key = 'c', }, }, - footer = { "", "Hello World!" }, + footer = function() + return { '', GetRandomMessage() } + end, }, hide = { statusline = false, |
