Skip to content

fresh-milkshake/gov

Repository files navigation

Gov Logo

Gov Programming Language

A satirical programming language with bureaucratic syntax and strong static typing.

cpp License: MIT Build and Release

WebsiteInstallationDocsVS Code Extension

Overview

Gov is a satirical programming language that uses bureaucratic terminology to create fully functional programs. Every program must start with a declaration of love for the government and use polite requests "PLEASE" for some operations.

Features

  • Full programming language: Variables, loops, conditions, functions
  • Static typing: Strong type system with automatic conversions
  • Satirical syntax: All commands use bureaucratic terminology
  • Ready interpreter: Includes debugger and AST parser
  • VS Code support: Syntax highlighting extension

Quick Start

Installation

Using CMake

# Create build directory
mkdir build && cd build

# Configure and build
cmake .. -DCMAKE_BUILD_TYPE=Release
cmake --build . --config Release

# Run a program
./bin/gov examples/hello_world.gov

Example Program

!I_LOVE_GOVERNMENT

PRAISE_LEADER "Hello, World!"

PLEASE DECLARE_VARIABLE "Counter" AS INTEGER
PLEASE SET Counter TO 0

FOR_THE_PEOPLE Counter LESS_THAN 3 DO
    PRAISE_LEADER "Long live the Supreme Leader!"
    PLEASE INCREMENT Counter BY 1
END_FOR_THE_PEOPLE

Interpreter Commands

  • ./gov <file.gov> - run program
  • ./gov parse <file.gov> - show AST structure
  • ./gov debug <file.gov> - debug mode
  • ./gov --help / ./gov -h - help

Documentation

Full Documentation: GOV_LANGUAGE_DOCUMENTATION.md

Examples

Ready programs in examples/ folder:

VS Code Support

Install the extension from extension/ folder for .gov file syntax highlighting.

License

This project is licensed under the MIT License. See LICENSE for details.

About

A satirical programming language with bureaucratic syntax and strong static typing

Topics

Resources

License

Stars

Watchers

Forks