Skip to main content

Overview

Configure language server behavior in a .gluarc.json file at your workspace root. The file has full JSON schema support, so your editor validates settings and provides completions. Use the VS Code settings panel to edit .gluarc.json without writing JSON, or edit the file directly. Both update the same configuration.
The GLua Settings panel lets you configure GLuaLS without touching JSON. Changes write directly to .gluarc.json.

Opening the panel

Open GLuaLS: Open GLuaLS Settings from the Command Palette (Ctrl+Shift+P), click the GLuaLS status item, or right-click a .gluarc.json file in the Explorer. In a multi-root workspace, choose the folder to configure. The panel groups settings by the same top-level sections as .gluarc.json. Click Save to write your changes, or enable Auto-save settings in the panel header.
If you want to inspect the generated JSON, open .gluarc.json directly. You can edit both the settings panel and the JSON file, and they stay in sync.

Auto-save behavior

Auto-save is off by default. Click Save after editing. To change auto-save behavior, toggle Auto-save settings in the panel header or set gluals.gmod.settingsAutoSave in your VS Code settings.

Manual configuration (.gluarc.json)

Creating your config

Create a .gluarc.json file at the root of your workspace:
Use the settings menu instead of editing the JSON file directly. This helps you avoid config mistakes.
.gluarc.json
The $schema property enables IDE validation and autocomplete for the file itself. The settings panel can also create the file for you. Run GLuaLS: Create GLuaLS Settings from the Command Palette. Most projects do not need a starter config. Add only the settings you want to change so new defaults can apply automatically.

Config file priority

When a workspace has multiple config files, GLuaLS uses this priority order (highest first):
  1. .gluarc.json
  2. .luarc.json
  3. .emmyrc.json
  4. .emmyrc.lua
.gluarc.json is exclusive. If it exists, GLuaLS ignores all other config files.

Configuration reference

The config file is split into top-level sections. Each page lists the available .gluarc.json options and related VS Code settings:

Garry's Mod settings

Realm analysis, network checks, scripted classes, hooks, and VGUI

Diagnostics

Enable, disable, and tune severity of all diagnostic codes

Completion

Autocomplete behavior, call snippets, postfix trigger, auto-require

Formatting

Built-in presets, style overrides, external formatter configuration

Workspace

Library paths, ignore patterns, module map, encoding

Hints & Hover

Inlay hints, inline values, hover, semantic tokens, signature help

Runtime & Strict

Non-standard symbols, strict type checking, special functions

Annotations management

Auto-download Garry’s Mod wiki annotations, custom annotation paths

VS Code extension settings

Extension settings control the debugger, AI integration, UI preferences, and annotation downloads. Open VS Code Settings and search for gluals to find them. Use .gluarc.json for analysis behavior. Its settings take precedence over matching VS Code workspace settings.