Skip to content

how to view the Git Icon for toggleterm executable? #192

Answered by vyfor
PCesteban asked this question in Q&A
Discussion options

You must be logged in to vote

This should do it:

{
  hooks = {
    pre_activity = function(opts)
      if opts.filetype == 'toggleterm' then
        local ft = opts.filename:match '%d+:([^.:&;]+)'
        if ft and ft ~= '' then opts.filetype = ft end
      end
    end,
  },
  assets = {
    lazygit = {
      name = 'Lazygit',
      tooltip = 'Terminal UI for Git commands',
      type = 'vcs',
    },
  }
}

You can add other executables to the assets list as well

Replies: 1 comment 9 replies

Comment options

You must be logged in to vote
9 replies
@vyfor
Comment options

vyfor Feb 3, 2025
Maintainer

@vyfor
Comment options

vyfor Feb 3, 2025
Maintainer

@PCesteban
Comment options

@vyfor
Comment options

vyfor Feb 4, 2025
Maintainer

Answer selected by PCesteban
@vyfor
Comment options

vyfor Feb 4, 2025
Maintainer

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants