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

Bug: Recent commit breaks external GitHub theme #602

Closed
2 tasks done
appelgriebsch opened this issue Mar 8, 2022 · 5 comments
Closed
2 tasks done

Bug: Recent commit breaks external GitHub theme #602

appelgriebsch opened this issue Mar 8, 2022 · 5 comments

Comments

@appelgriebsch
Copy link

Self Checks

  • I'm using the latest lualine.
  • I didn't find the issue in exsisting issues or prs.

How to reproduce the problem

The most recent commit breaks GitHub theme (https://github.com/projekt0n/github-nvim-theme/blob/main/LUALINE.md).

Expected behaviour

Up until recently the setup of lualine and Github theme resulted in this:
image

Actual behaviour

With the most recent commit the integration of the GitHub theme is broken and it looks like so:
image

Minimal config to reproduce the issue

see https://github.com/projekt0n/github-nvim-theme/blob/main/LUALINE.md

Config
@appelgriebsch appelgriebsch added the bug Something isn't working label Mar 8, 2022
@uolot
Copy link

uolot commented Mar 8, 2022

Same problem here, with the same colorscheme.

@shadmansaleh
Copy link
Member

shadmansaleh commented Mar 8, 2022

Just installed github colorscheme and placed github in lualines theme option and it's working as expected 🤷‍♂️

Screenshot

Can you check which commit broke it for you and if there's anything peculiar about you config . Because I Can't reproduce it.

Also minimal config means a config with only required plugins installed (Here only lualine and the colorscheme in question nothing else) and all the necessary config (not just lualines config anything that effects neovims default state need to be provided)

@appelgriebsch
Copy link
Author

For me it broke with the most recent commit. I used the minimal config as shown on the GitHub theme site for the Lualine configuration via packer: https://github.com/projekt0n/github-nvim-theme/blob/main/LUALINE.md

@shadmansaleh
Copy link
Member

I used the minimal config as shown on the GitHub theme site for the Lualine configuration via packer:

Like I said that's not minimal config :/ There's still too many things that can vary .

One very important question since you're using packer . Are you certain your colorscheme is loaded before lualine ?

Try adding

vim.cmd('packadd  github-nvim-theme')

before your call to lualine setup

@appelgriebsch
Copy link
Author

One very important question since you're using packer . Are you certain your colorscheme is loaded before lualine ?

That's a good hint...

On the GitHub theme site it mentions this setting:

use {
  "hoob3rt/lualine.nvim",
  config = function()
    require("lualine").setup {
      options = {
        theme = "github" -- or "auto"
        -- ... your lualine config
      }
    }
  end
}
use {
  "projekt0n/github-nvim-theme",
  after = "lualine.nvim", -- <- remove this line
  config = function()
    require("github-theme").setup({
      theme_style = "dark_default"
      -- your github config
    })
  end
}

which loads the theme AFTER lualine. So when turning it around to this it works:

use {
  "hoob3rt/lualine.nvim",
  after = "github-nvim-theme", -- <- add this line instead
  config = function()
    require("lualine").setup {
      options = {
        theme = "github" -- or "auto"
        -- ... your lualine config
      }
    }
  end
}
use {
  "projekt0n/github-nvim-theme",
  config = function()
    require("github-theme").setup({
      theme_style = "dark_default"
      -- your github config
    })
  end
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants