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

Integrate the "harpoon sorter" configuration recipe #178

Open
willothy opened this issue Oct 13, 2023 · 2 comments
Open

Integrate the "harpoon sorter" configuration recipe #178

willothy opened this issue Oct 13, 2023 · 2 comments
Labels
enhancement New feature or request
Milestone

Comments

@willothy
Copy link
Owner

Many people use harpoon. I should integrate the harpoon sorter that's in the wiki so that it can be a zero-config (but opt-in) feature.

@willothy willothy added the enhancement New feature or request label Oct 13, 2023
@sjclayton
Copy link

sjclayton commented Oct 17, 2023

That might be a good idea... Maybe you also could integrate something that would show the status and index of the file within a component... something like I've done here

   local HarpoonIdx = {
        text = function(buffer)
          local harpoon = require('harpoon.mark')
          local marked = harpoon.status()
          local idx = harpoon.get_index_of(buffer.path)

          if marked and idx ~= nil then
            return ' ' .. idx .. ' '
          end
          return ' '
        end,
        fg = 'TabLine',
      }

Maybe make it toggleable in the opts somehow as well...

@willothy
Copy link
Owner Author

That might be a good idea... Maybe you also could integrate something that would show the status and index of the file within a component... something like I've done here

   local HarpoonIdx = {

        text = function(buffer)

          local harpoon = require('harpoon.mark')

          local marked = harpoon.status()

          local idx = harpoon.get_index_of(buffer.path)



          if marked and idx ~= nil then

            return ' ' .. idx .. ' '

          end

          return ' '

        end,

        fg = 'TabLine',

      }


Maybe make it toggleable in the opts somehow as well...

Maybe! I think I will likely avoid adding to the default config though as the point of cokelike is to build your own statusline. However, would be great to have something like that in the wiki as a config recipe!

@willothy willothy added this to the 0.5.0 Release milestone Oct 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants