Catalog · How the catalog works
kodepas
Free and opensource Software Development Kit for Pascal
- ★ 1 on GitHub
Anyone may press Interesting, signed in or not. It helps others find this project.
README

KodePas 2
KodePas 2 is a lightweight project manager for Free Pascal and Lazarus. It is
the active implementation at the repository root. The original 2020 SDK is
preserved under legacy/ and is not used by the current
build.
Repository layout
src/— current command-line implementationtests/andscripts/— core and integration testslegacy/— archived KodePas 1 source, vendored Lazarus files and binaries
Requirements
- Free Pascal 3.2.2 or newer
- Lazarus 4.x only when building
lazarus-guiprojects
KodePas never downloads or executes project templates from an unsigned remote source. The initial templates are embedded in the binary so project creation is deterministic and works offline.
Build
make
./build/kodepas versionWithout make:
mkdir -p build/units
fpc -Fusrc -FEbuild -FUbuild/units src/kodepas.lprCommands
kodepas doctor
kodepas new <name> [--type console|lazarus-gui]
kodepas build [--release]
kodepas run [-- <program arguments>]
kodepas test
kodepas clean
kodepas versionNew projects contain a portable kodepas.ini manifest:
[project]
version=2
name=hello_pascal
type=console
source=src/main.pas
output=build/hello_pascalAll paths in the manifest must be relative to the project. KodePas rejects
absolute paths and parent-directory traversal before writing or deleting files.
The output must be an extensionless direct child of build/; Lazarus GUI
projects use build/<project-name> so the manifest and .lpi target stay in
sync across platforms.
kodepas run rebuilds the project, forwards arguments placed after --, and
connects the program directly to the current standard input, output, and error
streams. The program's exit code is returned unchanged.
Tests
make testThe test suite verifies manifest parsing, safe paths, both project scaffolds,
the CLI lifecycle, compilation of a console project, and Lazarus compilation
when lazbuild is available.
Migrating from KodePas 1
KodePas 1, now archived in legacy/, used local.ini and
mutated Lazarus XML files during every build. Migrate projects manually for
now:
- Keep the Pascal source and
.lpifiles. - Create
kodepas.iniusing the example above. - Use
type=consolefor a direct FPC program ortype=lazarus-guifor an existing.lpiproject. - Point
sourceat the main.pas/.lpror.lpifile. - Keep generated output below
build/.
Web, Node and Hybrid modes from the legacy CLI are intentionally not carried forward because they depended on unavailable or unsafe external tooling.

