SattLint is a Python toolkit for SattLine projects. It provides configurable static analysis, ICF validation, graphics-rule analysis, and an interactive terminal UI.
- Check whether a SattLine file parses correctly
- Analyze a full program or library together with its dependencies
- Find issues such as unused variables, written-but-never-read variables, and shadowing
- Validate ICF configuration files and graphics companion files
- Windows or Linux
- Python 3.13 or newer
- A local copy of your SattLine code
Install the released package with pip.
python3 -m pip install --user sattlintpy -m pip install --user sattlintThis installs the sattlint command for your user account.
sattlintTo run the latest code from the repository instead of the released package:
git clone https://github.com/SorenHJohansen/SattLint.git
cd SattLint
python3 -m pip install --user .Start the interactive terminal UI:
sattlintOpen a configuration first (File → Open Configuration or File → New Configuration), then use the Analyze view to pick analyzers and run checks.
sattlint takes no arguments; all CLI subcommands and flags have been removed
and every capability is reachable from the Textual UI. Supplying arguments
returns a usage error (exit code 2).
Exit codes:
0— success (the TUI launched and quit cleanly)2— arguments were supplied tosattlint
sattlintOpens the Textual interactive terminal UI. The app starts with no configuration loaded; use File → Open Configuration or File → New Configuration to load or create a project.
Views (switch with Ctrl+1…Ctrl+5 or the tabs at the top):
- Analyze — select analyzers to run and start checks
- Results — browse and inspect previous analysis runs
- Configuration Settings — set directories, targets, and mode
- App Settings — run history, logging, and Change Review output
- Output — generate Change Review artifacts
The File menu also offers Help (first-run guidance and keyboard shortcuts) and Quit.
A .slproj project file captures all analysis settings in a single
checked-in file: targets, directories, mode, and output/cache paths. Paths
inside a .slproj are relative to the file itself, so projects are portable
across machines.
- Use File → New Configuration in the UI to scaffold a new
.slprojin the current directory. - Use File → Open Configuration to load an existing
.slproj. - Project settings merge over
~/.config/sattlint/config.tomldefaults.
Prefer a .slproj project file over editing ~/.config/sattlint/config.toml
directly.
When SattLint analyzes a target, all SattLine discovery, dependency resolution,
and parsing run in sattline-parser's project layer (SattLineProject.load);
SattLint then re-validates and re-indexes the result into its ProjectGraph
analysis index before running analyzers.
The first time SattLint runs, it creates a config file automatically:
- Windows:
%APPDATA%\sattlint\config.toml - Linux:
~/.config/sattlint/config.toml
For a portable, checked-in setup, create a .slproj project file from the
UI's File → New Configuration action instead; project settings merge over
these config defaults (see Project Files).
-
Start SattLint with
sattlint -
Use File → Open Configuration or File → New Configuration to load a project
-
Select Configuration Settings (or press
Ctrl+3) and configure:program_dir— your SattLine program folderABB_lib_dir— shared or ABB librariesother_lib_dirs— any additional librariesanalyzed_programs_and_libraries— what to analyzeicf_dir— directory containing ICF files used for ICF validation
Changes are saved automatically to the configuration file.
-
Select Analyze to run checks
Note: Use names without file extensions (e.g.
MyProgram, notMyProgram.s).
Update the released package from PyPI:
python3 -m pip install --user --upgrade sattlintFor a source checkout, reinstall with python3 -m pip install --user ..
SattLint validates graphics companion files (.g) automatically whenever it
loads a program or library. Graphics issues — invalid bindings,
composite-record mismatches, and unresolved picture display paths — are
reported alongside the validation output for the affected target.
To dig deeper from the UI:
- Open Analyze and run PictureDisplay paths to check that every PictureDisplay button path points to a real screen or module.
- Run ICF configuration to validate the
.icfconnection files undericf_diragainst their referenced programs.
The sattlint script is not on your PATH. After a pip install --user,
scripts are placed in ~/.local/bin on Linux (or
%APPDATA%\Python\Python313\Scripts on Windows); add that directory to your
PATH and restart your terminal.
Install Python 3.13+ and reinstall with python3 -m pip install --user --upgrade sattlint.
- Names must not include file extensions
- Paths in config must be correct
- Mode (
official/draft) must match your files
Add missing folders to ABB_lib_dir or other_lib_dirs.
Results are cached per configuration. Opening a configuration refreshes the cached ASTs automatically; if results still look stale, re-run the analysis from the Analyze view. Completed runs are kept in the Results view, and App Settings → Run History controls how many runs are retained.
See CONTRIBUTING.md for development setup, tests, and tooling.
SattLint is released under the MIT License.