mirror of
https://github.com/stevearc/aerial.nvim
synced 2024-09-08 02:35:44 +02:00
ci: use nvim-typecheck-action v2
This commit is contained in:
parent
bd5f141a54
commit
690290be7f
4 changed files with 13 additions and 13 deletions
2
.github/workflows/tests.yml
vendored
2
.github/workflows/tests.yml
vendored
|
@ -30,7 +30,7 @@ jobs:
|
|||
runs-on: ubuntu-22.04
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: stevearc/nvim-typecheck-action@v1
|
||||
- uses: stevearc/nvim-typecheck-action@v2
|
||||
with:
|
||||
path: lua
|
||||
|
||||
|
|
|
@ -87,8 +87,8 @@ M.show_help = function(action_module, keymaps)
|
|||
end
|
||||
vim.keymap.set("n", "q", "<cmd>close<CR>", { buffer = bufnr, nowait = true })
|
||||
vim.keymap.set("n", "<c-c>", "<cmd>close<CR>", { buffer = bufnr })
|
||||
vim.api.nvim_buf_set_option(bufnr, "modifiable", false)
|
||||
vim.api.nvim_buf_set_option(bufnr, "bufhidden", "wipe")
|
||||
vim.bo[bufnr].modifiable = false
|
||||
vim.bo[bufnr].bufhidden = "wipe"
|
||||
|
||||
local editor_width = vim.o.columns
|
||||
local editor_height = vim.o.lines - vim.o.cmdheight
|
||||
|
|
|
@ -8,9 +8,9 @@ local util = require("aerial.util")
|
|||
local M = {}
|
||||
|
||||
M.clear_buffer = function(bufnr)
|
||||
vim.api.nvim_buf_set_option(bufnr, "modifiable", true)
|
||||
vim.bo[bufnr].modifiable = true
|
||||
vim.api.nvim_buf_set_lines(bufnr, 0, -1, false, {})
|
||||
vim.api.nvim_buf_set_option(bufnr, "modifiable", false)
|
||||
vim.bo[bufnr].modifiable = false
|
||||
end
|
||||
|
||||
-- Resize all windows displaying this aerial buffer
|
||||
|
@ -177,9 +177,9 @@ M.update_aerial_buffer = function(buf)
|
|||
resize_all_wins(aer_bufnr, max_len, #lines)
|
||||
|
||||
-- Insert lines into buffer
|
||||
vim.api.nvim_buf_set_option(aer_bufnr, "modifiable", true)
|
||||
vim.bo[aer_bufnr].modifiable = true
|
||||
vim.api.nvim_buf_set_lines(aer_bufnr, 0, -1, false, lines)
|
||||
vim.api.nvim_buf_set_option(aer_bufnr, "modifiable", false)
|
||||
vim.bo[aer_bufnr].modifiable = false
|
||||
|
||||
local ns = vim.api.nvim_create_namespace("aerial")
|
||||
vim.api.nvim_buf_clear_namespace(aer_bufnr, ns, 0, -1)
|
||||
|
|
|
@ -19,11 +19,11 @@ local function create_aerial_buffer(bufnr)
|
|||
vim.api.nvim_buf_set_var(bufnr, "aerial_buffer", aer_bufnr)
|
||||
-- Set buffer options
|
||||
vim.api.nvim_buf_set_var(aer_bufnr, "source_buffer", bufnr)
|
||||
vim.api.nvim_buf_set_option(aer_bufnr, "buftype", "nofile")
|
||||
vim.api.nvim_buf_set_option(aer_bufnr, "bufhidden", "wipe")
|
||||
vim.api.nvim_buf_set_option(aer_bufnr, "buflisted", false)
|
||||
vim.api.nvim_buf_set_option(aer_bufnr, "swapfile", false)
|
||||
vim.api.nvim_buf_set_option(aer_bufnr, "modifiable", false)
|
||||
vim.bo[aer_bufnr].buftype = "nofile"
|
||||
vim.bo[aer_bufnr].bufhidden = "wipe"
|
||||
vim.bo[aer_bufnr].buflisted = false
|
||||
vim.bo[aer_bufnr].swapfile = false
|
||||
vim.bo[aer_bufnr].modifiable = false
|
||||
|
||||
if config.highlight_on_hover or config.autojump then
|
||||
vim.api.nvim_create_autocmd("CursorMoved", {
|
||||
|
@ -106,7 +106,7 @@ local function setup_aerial_win(src_winid, aer_winid, aer_bufnr)
|
|||
vim.api.nvim_win_set_var(aer_winid, "source_win", src_winid)
|
||||
vim.api.nvim_win_set_var(src_winid, "aerial_win", aer_winid)
|
||||
-- Set the filetype only after we enter the buffer so that ftplugins behave properly
|
||||
vim.api.nvim_buf_set_option(aer_bufnr, "filetype", "aerial")
|
||||
vim.bo[aer_bufnr].filetype = "aerial"
|
||||
local width = vim.b[aer_bufnr].aerial_width
|
||||
if width and (not vim.w[aer_winid].aerial_set_width or config.layout.resize_to_content) then
|
||||
vim.api.nvim_win_set_width(aer_winid, width)
|
||||
|
|
Loading…
Reference in a new issue