Skip to content

Commit 18ae2db

Browse files
authored
Merge pull request #2553 from emmericp/trust-all-plugins
Add CLI option to trust all plugins
2 parents 28322ce + 606e9cd commit 18ae2db

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

script/global.d.lua

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,3 +90,7 @@ SOCKET = 0
9090

9191
-- Allowing the use of the root directory or home directory as the workspace
9292
FORCE_ACCEPT_WORKSPACE = false
93+
94+
-- Trust all plugins that are being loaded by workspace config files.
95+
-- This is potentially unsafe for normal use and meant for usage in CI environments only.
96+
TRUST_ALL_PLUGINS = false

script/plugin.lua

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,9 @@ end
7373
---@async
7474
---@param scp scope
7575
local function checkTrustLoad(scp)
76+
if TRUST_ALL_PLUGINS then
77+
return true
78+
end
7679
local pluginPath = scp:get('pluginPath')
7780
local filePath = LOGPATH .. '/trusted'
7881
local trusted = util.loadFile(filePath)

0 commit comments

Comments
 (0)