diff --git a/.stylua.toml b/.stylua.toml index 3cfeffdc..020ce912 100644 --- a/.stylua.toml +++ b/.stylua.toml @@ -1,3 +1,5 @@ column_width = 100 indent_type = "Spaces" indent_width = 2 +[sort_requires] +enabled = true diff --git a/lua/oil/adapters/ssh.lua b/lua/oil/adapters/ssh.lua index b69b0748..c717fb14 100644 --- a/lua/oil/adapters/ssh.lua +++ b/lua/oil/adapters/ssh.lua @@ -1,12 +1,12 @@ local config = require("oil.config") local constants = require("oil.constants") -local fs = require("oil.fs") local files = require("oil.adapters.files") +local fs = require("oil.fs") local loading = require("oil.loading") -local permissions = require("oil.adapters.files.permissions") -local sshfs = require("oil.adapters.ssh.sshfs") local pathutil = require("oil.pathutil") +local permissions = require("oil.adapters.files.permissions") local shell = require("oil.shell") +local sshfs = require("oil.adapters.ssh.sshfs") local util = require("oil.util") local M = {} diff --git a/lua/oil/adapters/ssh/sshfs.lua b/lua/oil/adapters/ssh/sshfs.lua index 6b35dc52..25917498 100644 --- a/lua/oil/adapters/ssh/sshfs.lua +++ b/lua/oil/adapters/ssh/sshfs.lua @@ -1,7 +1,7 @@ +local SSHConnection = require("oil.adapters.ssh.connection") local cache = require("oil.cache") local constants = require("oil.constants") local permissions = require("oil.adapters.files.permissions") -local SSHConnection = require("oil.adapters.ssh.connection") local util = require("oil.util") ---@class (exact) oil.sshFs diff --git a/lua/oil/mutator/init.lua b/lua/oil/mutator/init.lua index 7240572e..c3bfc5ea 100644 --- a/lua/oil/mutator/init.lua +++ b/lua/oil/mutator/init.lua @@ -1,3 +1,5 @@ +local Progress = require("oil.mutator.progress") +local Trie = require("oil.mutator.trie") local cache = require("oil.cache") local columns = require("oil.columns") local config = require("oil.config") @@ -7,8 +9,6 @@ local oil = require("oil") local parser = require("oil.mutator.parser") local pathutil = require("oil.pathutil") local preview = require("oil.mutator.preview") -local Progress = require("oil.mutator.progress") -local Trie = require("oil.mutator.trie") local util = require("oil.util") local view = require("oil.view") local M = {} diff --git a/lua/oil/mutator/progress.lua b/lua/oil/mutator/progress.lua index d007150c..1372c4ea 100644 --- a/lua/oil/mutator/progress.lua +++ b/lua/oil/mutator/progress.lua @@ -1,5 +1,5 @@ -local config = require("oil.config") local columns = require("oil.columns") +local config = require("oil.config") local layout = require("oil.layout") local loading = require("oil.loading") local util = require("oil.util") diff --git a/tests/altbuf_spec.lua b/tests/altbuf_spec.lua index d0a4453e..2f1e8e3f 100644 --- a/tests/altbuf_spec.lua +++ b/tests/altbuf_spec.lua @@ -1,7 +1,7 @@ require("plenary.async").tests.add_to_env() +local fs = require("oil.fs") local oil = require("oil") local test_util = require("tests.test_util") -local fs = require("oil.fs") a.describe("Alternate buffer", function() after_each(function() diff --git a/tests/files_spec.lua b/tests/files_spec.lua index 96b143a3..3e5e4668 100644 --- a/tests/files_spec.lua +++ b/tests/files_spec.lua @@ -1,7 +1,7 @@ require("plenary.async").tests.add_to_env() +local TmpDir = require("tests.tmpdir") local files = require("oil.adapters.files") local test_util = require("tests.test_util") -local TmpDir = require("tests.tmpdir") a.describe("files adapter", function() local tmpdir diff --git a/tests/regression_spec.lua b/tests/regression_spec.lua index 1c0373e1..f730ee5e 100644 --- a/tests/regression_spec.lua +++ b/tests/regression_spec.lua @@ -1,7 +1,7 @@ require("plenary.async").tests.add_to_env() +local TmpDir = require("tests.tmpdir") local oil = require("oil") local test_util = require("tests.test_util") -local TmpDir = require("tests.tmpdir") local view = require("oil.view") a.describe("regression tests", function()