Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot change default options without sourcing nvim config again #179

Closed
pansy27 opened this issue Jul 7, 2022 · 2 comments
Closed

Cannot change default options without sourcing nvim config again #179

pansy27 opened this issue Jul 7, 2022 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@pansy27
Copy link

pansy27 commented Jul 7, 2022

Description

Hello.
I was trying to change the default option of solid backgroud to transparent but wasn't successful in doing so.
The changes i made are not being loaded unless i manually source my neovim config each time i open a new instance of neovim.
Tried changing comments to italic to test and indeed the nightfox.setup function doesn't work unless the config is sourced again.

Tried doing :NightfoxStatus and :NightfoxClean too. It didn't throw any errors.

Behavior

Expected behavior
The changes i made should get automatically loaded each time.

Screenshots

output of :NightfoxStatus

02_59_41

before sourcing my config: comments aren't italic, transparent isn't working

03_05_32

after sourcing my config again

03_06_24

Configuration

-- nightfox options 
require('nightfox').setup({
  options = {
    transparent = true,
    styles = {
      comments = "italic",
    },
  },
})

Reproduce

  1. install the theme through vim plug
  2. set theme as nightfox through colorscheme dayfox, change relevant options inside a lua block in init.vim

Additional info

neovim version: NVIM v0.7.2
Build type: Release
terminal: alacritty
platform: arch linux

@pansy27 pansy27 added the bug Something isn't working label Jul 7, 2022
@EdenEast
Copy link
Owner

EdenEast commented Jul 7, 2022

In your configuration make sure that you are setting up nightfox's configuration before setting your colorscheme with the :colorscheme command.

If you set the colorscheme before nightfox's settings are set it will use the default values.

lua << EOF
require('nightfox').setup({
  -- ...
})
EOF
colorscheme dayfox

@EdenEast EdenEast self-assigned this Jul 7, 2022
@pansy27
Copy link
Author

pansy27 commented Jul 8, 2022

That did the job. Thanks a lot :D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants