To bootstrap your development environment, the most convenient method is to install mise.
After installing mise, you can run the following command to install all necessary build dependencies for this project:
mise installAlternatively, you can install the relevant dependencies manually by reading the mise.toml file, and installing the dependencies listed there.
To setup the language server in your editor, first install terragrunt-ls by running the following at the root of this repository:
go install(In the future, this will be available as a precompiled binary for download)
Then follow the instructions below for your editor:
To install the Visual Studio Code extension, you can manually compile the extension locally, then install it from the .vsix file.
-
Navigate to the
vscode-extensiondirectory:cd vscode-extension -
Ensure you have vsce (Visual Studio Code Extension CLI) & the typescript compiler installed. If you don't have it, you can install it globally using npm:
npm install -g @vscode/vsce npm install -g typescript
-
Install local javascript packages
npm install
-
Run the following command to package the extension:
vsce package
-
This will create a
.vsixfile in thevscode-extensiondirectory (e.g.terragrunt-ls-0.0.1.vsix). You can install this file directly as a Visual Studio Code extension, like so:code --install-extension terragrunt-ls-0.0.1.vsix
Installation from the Visual Studio Extensions Marketplace coming soon!
For Neovim, you can install the neovim plugin by adding the following to your editor:
-- ~/.config/nvim/lua/custom/plugins/terragrunt-ls.lua
return {
{
"gruntwork-io/terragrunt-ls",
-- To use a local version of the Neovim plugin, you can use something like following:
-- dir = vim.fn.expand '~/repos/src/github.com/gruntwork-io/terragrunt-ls',
ft = 'hcl',
config = function()
local terragrunt_ls = require 'terragrunt-ls'
terragrunt_ls.setup {
cmd_env = {
-- If you want to see language server logs,
-- set this to the path you want.
-- TG_LS_LOG = vim.fn.expand '/tmp/terragrunt-ls.log',
},
}
if terragrunt_ls.client then
vim.api.nvim_create_autocmd('FileType', {
pattern = 'hcl',
callback = function()
vim.lsp.buf_attach_client(0, terragrunt_ls.client)
end,
})
end
end,
},
}Installation from Mason coming soon!
For now, clone this repo and point to the zed-extension directory when installing dev extension
Installing from extension page coming soon!