Hyper theme will crash if the user has no oldfiles history

Open Beginner friendly
#480 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
1/5
Estimated time
Under an hour
Newbie friendliness
78/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Stale
Tech stack
lua
Domain
tooling

Research direction

Start in lua/dashboard/theme/hyper.lua around line 179, where mru_list uses utils.get_mru_list() to determine the OS separator. Check the separator handling for an empty MRU result, then verify that the Hyper theme starts successfully on a fresh Neovim installation with no oldfiles history.

Written by the indexing model from the issue text.

Description

https://github.com/nvimdev/dashboard-nvim/blob/fabf5feec96185817c732d47d363f34034212685/lua/dashboard/theme/hyper.lua#L179

mru_list takes the result of utils.get_mru_list() to figure out which OS separator it should use, but this function will always return {} on a fresh install of Neovim.

Lua already provides a safe way to get the directory separator for all systems using package.config:

local sep = package.config:sub(1, 1)
Dominant language
Lua
Stars
2.9k
Forks
201
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from nvimdev/dashboard-nvim

All issues in nvimdev/dashboard-nvim

Similar issues

More Lua issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.