style: sort requires

This commit is contained in:
Folke Lemaitre 2023-10-09 11:25:42 +02:00
parent f0cfbf9952
commit 22bf6ae04b
No known key found for this signature in database
GPG Key ID: 41F8B1FBACAE2040
22 changed files with 37 additions and 34 deletions

View File

@ -1,5 +1,5 @@
local Util = require("lazy.core.util")
local Loader = require("lazy.core.loader")
local Util = require("lazy.core.util")
---@class LazyCmdHandler:LazyHandler
local M = {}

View File

@ -1,6 +1,6 @@
local Util = require("lazy.core.util")
local Config = require("lazy.core.config")
local Loader = require("lazy.core.loader")
local Util = require("lazy.core.util")
---@class LazyEventOpts
---@field event string

View File

@ -1,5 +1,5 @@
local Util = require("lazy.core.util")
local Config = require("lazy.core.config")
local Util = require("lazy.core.util")
---@class LazyHandler
---@field type LazyHandlerTypes

View File

@ -1,5 +1,5 @@
local Util = require("lazy.core.util")
local Loader = require("lazy.core.loader")
local Util = require("lazy.core.util")
---@class LazyKeysBase
---@field desc? string

View File

@ -1,8 +1,8 @@
local Util = require("lazy.core.util")
local Cache = require("lazy.core.cache")
local Config = require("lazy.core.config")
local Handler = require("lazy.core.handler")
local Plugin = require("lazy.core.plugin")
local Cache = require("lazy.core.cache")
local Util = require("lazy.core.util")
---@class LazyCoreLoader
local M = {}

View File

@ -1,6 +1,6 @@
local Config = require("lazy.core.config")
local Util = require("lazy.core.util")
local Handler = require("lazy.core.handler")
local Util = require("lazy.core.util")
---@class LazyCorePlugin
local M = {}

View File

@ -54,7 +54,7 @@ function M.check()
local spec = Config.spec
if spec == nil then
error("No plugins loaded. Did you forget to run `require(\"lazy\").setup()`?")
error('No plugins loaded. Did you forget to run `require("lazy").setup()`?')
else
for _, plugin in pairs(spec.plugins) do
M.check_valid(plugin)

View File

@ -1,9 +1,9 @@
local Config = require("lazy.core.config")
local Manage = require("lazy.manage")
local Util = require("lazy.util")
local Plugin = require("lazy.core.plugin")
local Git = require("lazy.manage.git")
local Manage = require("lazy.manage")
local Plugin = require("lazy.core.plugin")
local State = require("lazy.state")
local Util = require("lazy.util")
local M = {}

View File

@ -1,7 +1,7 @@
local Util = require("lazy.util")
local Semver = require("lazy.manage.semver")
local Config = require("lazy.core.config")
local Process = require("lazy.manage.process")
local Semver = require("lazy.manage.semver")
local Util = require("lazy.util")
local M = {}

View File

@ -1,6 +1,6 @@
local Config = require("lazy.core.config")
local Runner = require("lazy.manage.runner")
local Plugin = require("lazy.core.plugin")
local Runner = require("lazy.manage.runner")
local M = {}

View File

@ -1,7 +1,7 @@
local Config = require("lazy.core.config")
local Util = require("lazy.util")
local Plugin = require("lazy.core.plugin")
local Loader = require("lazy.core.loader")
local Plugin = require("lazy.core.plugin")
local Util = require("lazy.util")
local M = {}

View File

@ -1,5 +1,5 @@
local Task = require("lazy.manage.task")
local Config = require("lazy.core.config")
local Task = require("lazy.manage.task")
local Util = require("lazy.util")
---@class RunnerOpts

View File

@ -1,5 +1,5 @@
local Util = require("lazy.util")
local Config = require("lazy.core.config")
local Util = require("lazy.util")
---@type table<string, LazyTaskDef>
local M = {}

View File

@ -1,6 +1,6 @@
local Config = require("lazy.core.config")
local Git = require("lazy.manage.git")
local Lock = require("lazy.manage.lock")
local Config = require("lazy.core.config")
local Util = require("lazy.util")
---@type table<string, LazyTaskDef>

View File

@ -1,6 +1,6 @@
local Util = require("lazy.util")
local Loader = require("lazy.core.loader")
local Config = require("lazy.core.config")
local Loader = require("lazy.core.loader")
local Util = require("lazy.util")
---@type table<string, LazyTaskDef>
local M = {}

View File

@ -1,5 +1,5 @@
local Util = require("lazy.util")
local Config = require("lazy.core.config")
local Util = require("lazy.util")
---@type LazyState
local M = {}

View File

@ -1,8 +1,8 @@
local require = require("lazy.core.util").lazy_require
local View = require("lazy.view")
local Config = require("lazy.core.config")
local Manage = require("lazy.manage")
local Util = require("lazy.util")
local Config = require("lazy.core.config")
local View = require("lazy.view")
local ViewConfig = require("lazy.view.config")
local M = {}

View File

@ -1,6 +1,6 @@
local Config = require("lazy.core.config")
local ViewConfig = require("lazy.view.config")
local Util = require("lazy.util")
local ViewConfig = require("lazy.view.config")
---@class LazyFloatOptions
---@field buf? number

View File

@ -1,10 +1,10 @@
local Util = require("lazy.util")
local Render = require("lazy.view.render")
local Config = require("lazy.core.config")
local ViewConfig = require("lazy.view.config")
local Git = require("lazy.manage.git")
local Diff = require("lazy.view.diff")
local Float = require("lazy.view.float")
local Git = require("lazy.manage.git")
local Render = require("lazy.view.render")
local Util = require("lazy.util")
local ViewConfig = require("lazy.view.config")
---@class LazyViewState
---@field mode string

View File

@ -1,9 +1,9 @@
local Config = require("lazy.core.config")
local Util = require("lazy.util")
local Sections = require("lazy.view.sections")
local Handler = require("lazy.core.handler")
local Git = require("lazy.manage.git")
local Handler = require("lazy.core.handler")
local Plugin = require("lazy.core.plugin")
local Sections = require("lazy.view.sections")
local Util = require("lazy.util")
local ViewConfig = require("lazy.view.config")
local Text = require("lazy.view.text")

View File

@ -1,3 +1,6 @@
indent_type = "Spaces"
indent_width = 2
column_width = 120
column_width = 120
[sort_requires]
enabled = true

View File

@ -1,6 +1,6 @@
local Util = require("lazy.util")
local Cache = require("lazy.core.cache")
local Helpers = require("tests.helpers")
local Util = require("lazy.util")
describe("util", function()
local rtp = vim.opt.rtp:get()