Welcome! This guide will walk you through everything you need to set up the Nitpick compiler on your Linux Mint machine, write and compile Nitpick programs, and report any bugs you find. Every step is spelled out — just follow along in order.
- What is Nitpick?
- Install Prerequisites
- Clone the Nitpick Repository
- Build the Compiler
- Your First Nitpick Program
- Install VS Code Syntax Highlighting
- Key Reference Files
- Compiling Programs — Quick Reference
- Exploring the Examples
- Nitpick Language Crash Course
- Prompts for Your AI Assistant
- How to Report Bugs
- Troubleshooting
Nitpick is a compiled systems programming language. Think of it like C or Rust, but with its own unique syntax. You write .npk files, compile them with the npkc compiler, and get a native executable you can run directly. It compiles down to machine code via LLVM — so the programs are fast.
Nitpick is under active development (version 0.18.0), so you may find bugs. That's exactly what we need your help with! When something doesn't work the way you'd expect, that's valuable information.
Open a terminal (Ctrl+Alt+T) and run these commands one at a time. Enter your password when prompted.
sudo apt updatesudo apt install -y build-essential cmake gitThis installs the C++ compiler (g++), the build system (cmake), and git for downloading the code.
Nitpick requires LLVM version 20. On Linux Mint 22.3 (based on Ubuntu 24.04), this is available in the default repositories:
sudo apt install -y llvm-20-devIf that doesn't work (e.g., you get "unable to locate package"), you may need to enable the universe repository first:
sudo add-apt-repository universe
sudo apt update
sudo apt install -y llvm-20-devsudo apt install -y liburing-devllvm-config-20 --version
cmake --version
g++ --versionYou should see:
- LLVM version 20.x.x (e.g., 20.1.2)
- CMake version 3.28.x or higher
- g++ version 13.x.x or similar
If any of those commands fail or show a version that's too old, stop here and let us know.
cd ~
git clone https://github.com/alternative-intelligence-cp/aria.git
cd ariacd ~
git clone git@github.com:alternative-intelligence-cp/aria.git
cd ariaAfter this, you should be inside the ~/aria directory. You can verify:
lsYou should see files like CMakeLists.txt, scripts/, examples/, tests/, etc.
The install script handles everything — prerequisite checking, building, and optional system-wide installation:
./install.sh --build-onlyThis will check prerequisites, then build npkc, aria-ls, npkpkg, aria-doc, and aria-safety. To also install them to /usr/local/bin:
sudo ./install.sh./scripts/build.shThis will:
- Create a
build/directory - Run CMake to configure the build
- Compile everything using all your CPU cores
This may take several minutes depending on your machine. You'll see a lot of output scrolling by — that's normal.
When it finishes, verify the compiler was built:
./build/npkc --helpYou should see the compiler's usage message listing all the flags and options. If you see that, congratulations — you have a working Nitpick compiler!
Common issues:
- "LLVM not found": Make sure
llvm-20-devis installed (sudo apt install llvm-20-dev) - "uring.h not found": Make sure
liburing-devis installed (sudo apt install liburing-dev) - Other errors: Copy the full error output and send it to us (see How to Report Bugs)
If you'd rather skip building from source, you can install a pre-built package:
cd aria
./packaging/build-deb.sh
sudo dpkg -i packaging/aria-lang_*_amd64.debTo uninstall: sudo dpkg --purge aria-lang
cd aria
./packaging/build-rpm.sh
sudo rpm -ivh ~/rpmbuild/RPMS/x86_64/aria-lang-*.x86_64.rpmSee INSTALL.md for all installation methods.
Open VS Code, create a new file called hello.npk, and paste this:
func:main = int32(){
print("Hello, World!");
pass(0);
};
func:failsafe = NIL(int32:err_code) {};
Save it somewhere you can find it (your home directory is fine).
In the terminal, navigate to where you saved the file and run:
~/aria/build/npkc hello.npk -o helloThis compiles hello.npk into an executable called hello.
./helloYou should see:
Hello, World!
func:main = int32()— declares the main function (entry point), returns an int32print("Hello, World!")— prints text to the screenpass(0)— returns 0 (success) from the function- The
};at the end closes the function (yes, functions end with};in Nitpick)
The Nitpick repository includes a VS Code extension for syntax highlighting.
cp -r ~/aria/vscode-aria ~/.vscode/extensions/aria-language-0.0.1Close VS Code completely and reopen it. (Or press Ctrl+Shift+P, type "Reload Window", and hit Enter.)
Open any .npk file. You should see syntax highlighting — keywords in one color, strings in another, comments greyed out, etc.
If it doesn't work, you can also try:
cd ~/aria/vscode-aria
code --install-extension .These are the important files to know about inside the ~/aria/ directory:
| File/Directory | What it is |
|---|---|
examples/basic/ |
Start here! 5 beginner examples (hello world, variables, functions, control flow, memory) |
examples/ |
Larger example programs (games, parsers, HTTP server, crypto, etc.) |
aria_ecosystem/programming_guide/ |
Comprehensive language documentation — 350+ topic files |
.internal/aria_specs.txt |
The complete language specification (7,000+ lines — reference, not tutorial) |
KNOWN_ISSUES.md |
Known bugs and limitations — check here before reporting |
ARCHITECTURE.md |
How the compiler works internally |
SAFETY.md |
Nitpick's three-layer safety system |
CHANGELOG.md |
Version history and changes |
tests/ |
400+ test files — great for seeing how features are used |
stdlib/ |
Standard library source code |
The programming guide at aria_ecosystem/programming_guide/ is organized by topic:
| Directory | Topics |
|---|---|
types/ |
All Nitpick types (int8-int64, uint8-uint64, flt32/flt64, bool, string, int128-int4096, and more) |
functions/ |
Function syntax, generics, closures, async |
control_flow/ |
if/else, while, till, pick (switch), loops |
operators/ |
All operators (+, -, *, /, comparisons, bitwise, etc.) |
memory_model/ |
Borrow system, wild blocks (unsafe), memory management |
modules/ |
Module system, imports, namespaces |
io_system/ |
File I/O, network I/O |
debugging/ |
Debug tools and techniques |
standard_library/ |
Standard library documentation |
advanced_features/ |
Advanced topics |
# Basic compile and run:
~/aria/build/npkc myfile.npk -o myprogram
./myprogram
# Compile with optimizations:
~/aria/build/npkc myfile.npk -o myprogram -O2
# See the generated LLVM IR (useful for bug reports):
~/aria/build/npkc myfile.npk --emit-llvm
# See the generated assembly:
~/aria/build/npkc myfile.npk --emit-asm
# Compile with verbose output (shows what the compiler is doing):
~/aria/build/npkc myfile.npk -o myprogram -v
# Compile a multi-file project (modules):
~/aria/build/npkc main.npk utils.npk -o myprogram
# Link against a C library (e.g., math):
~/aria/build/npkc myfile.npk -o myprogram -lmTip: You can create an alias so you don't have to type the full path every time. Add this to the end of your ~/.bashrc file:
alias npkc="$HOME/aria/build/npkc"Then open a new terminal (or run source ~/.bashrc), and you can just type:
npkc myfile.npk -o myprogramThe examples/basic/ directory has 5 beginner-friendly examples. Try compiling and running each one:
cd ~/aria/examples/basic
# Hello World
~/aria/build/npkc 01_hello_world.npk -o hello && ./hello
# Variables and Types
~/aria/build/npkc 02_variables.npk -o variables && ./variables
# Functions
~/aria/build/npkc 03_functions.npk -o functions && ./functions
# Control Flow (if/else, loops)
~/aria/build/npkc 04_control_flow.npk -o control_flow && ./control_flow
# Memory
~/aria/build/npkc 05_memory.npk -o memory && ./memoryAfter those, check out the more advanced examples in examples/:
ls ~/aria/examples/Look for things like rpn_calc.npk (calculator), tictactoe.npk (game), number_demo.npk, etc.
Here's a quick overview of how Nitpick differs from languages you might have seen:
int32:x = 42;
flt64:pi = 3.14159;
bool:done = false;
string:name = "Nitpick";
func:add = int32(int32:a, int32:b){
pass(a + b);
};
pass(value)is how you return a value (likereturnin other languages)- Functions end with
};(semicolon after the closing brace)
if(x > 10){
print("big");
}else{
print("small");
}
// While loop
while(x < 100){
x = x + 1;
}
// Till loop — counts from 0 to limit-1, step 1
// $ is the loop variable
till(10, 1){
print(`&{$}`); // prints 0 through 9
}
int32:age = 30;
print(`My age is &{age}`);
pick(value){
case(1){
print("one");
}
case(2){
print("two");
}
default{
print("other");
}
}
Functions return result types with .val (the value) and .err (error code):
func:divide = flt64(flt64:a, flt64:b){
if(b == 0.0){
fail(1); // return an error
}
pass(a / b); // return success
};
func:main = int32(){
result:r = divide(10.0, 3.0);
if(r.err != 0){
print("Error!");
}else{
// use r.val
}
pass(0);
};
Here are some prompts you can give Copilot (or any AI assistant) to help you write Nitpick code. Copy the relevant prompt and paste it into your AI chat.
I'm writing code in a new programming language called Nitpick. Here are the key syntax rules:
- Variables:
type:name = value;(e.g.,int32:x = 42;)- Functions:
func:name = returnType(type:param){ body };— note the semicolon after}- Return values: use
pass(value)instead ofreturn- Return errors: use
fail(code)instead of throwing- Print:
print("text")orprint(\&{variable}`)`- String interpolation: backtick strings with
&{expr}- Entry point:
func:main = int32(){ ... };- Comments:
//for line,/* */for block- If/else:
if(cond){ } else { }- While:
while(cond){ }- Till loop:
till(limit, step){ }—$is the loop variable- Pick (switch):
pick(val){ case(1){ } default{ } }- Types: int8, int16, int32, int64, uint8-uint64, flt32, flt64, bool, string
- Large integers: int128, int256, int512, int1024, int2048, int4096
- Result type:
result:r = func(); r.valfor value,r.errfor error code- The failsafe function is required as an error handler:
func:failsafe = NIL(int32:err_code) {};I have the language spec at
.internal/aria_specs.txtand examples inexamples/basic/in my project. Help me write Nitpick programs following these rules.
I have this [Python/JavaScript/etc.] code that I want to rewrite in Nitpick. Remember Nitpick uses
type:namefor variables (likeint32:x),pass()instead ofreturn, functions end with};, and string interpolation uses backticks with&{}. Please convert this code to Nitpick syntax:[paste your code here]
I'm getting a compiler error in Nitpick. The compiler is called
npkc. Here's my code and the error message. Can you help me figure out what's wrong? Remember Nitpick syntax requirestype:namefor variables,pass()for return values, and functions are declared asfunc:name = returnType(params){ body };Code: [paste code]
Error: [paste error]
I want to write a data analysis tool in Nitpick. Nitpick has large integer types (int128 up to int4096) which could be useful for crypto calculations. It also has flt64 for floating-point math. Help me write an Nitpick program that [describe what you want]. Remember the Nitpick syntax rules:
type:namefor variables,pass()to return,func:name = returnType(params){ body };for functions.
When you find something that doesn't work, crashes, or produces unexpected output, we need a bug report. Here's the template — copy this, fill it in, and send it to us:
=== ARIA BUG REPORT ===
Date: [today's date]
Reporter: [your name]
--- SUMMARY ---
[One sentence describing what went wrong]
--- WHAT I EXPECTED ---
[What you thought should happen]
--- WHAT ACTUALLY HAPPENED ---
[What actually happened — error message, wrong output, crash, etc.]
--- ARIA SOURCE CODE ---
[Paste the COMPLETE .aria file that triggers the bug. If it's multiple files,
include all of them.]
--- COMPILER COMMAND ---
[The exact command you ran, e.g.:]
~/aria/build/npkc myfile.npk -o myprogram
--- COMPILER OUTPUT ---
[Paste the COMPLETE output from the compiler. Include any error messages,
warnings, or crash output. If the program compiled but crashed when running,
include that output too.]
--- LLVM IR (if possible) ---
[Run: ~/aria/build/npkc myfile.npk --emit-llvm 2>&1 ]
[Paste the output here — this helps us debug. Skip if the compiler crashes
before producing IR.]
--- SYSTEM INFO ---
OS: Linux Mint 22.3
LLVM: [run: llvm-config-20 --version]
Compiler built: [run: git -C ~/aria log --oneline -1]
--- STEPS TO REPRODUCE ---
1. [Step-by-step what you did]
2. [So we can reproduce the exact problem]
3. [Include any setup needed]
--- SEVERITY ---
[ ] Crash — the compiler crashes or segfaults
[ ] Wrong output — program compiles but produces incorrect results
[ ] Compile error — valid code is rejected by the compiler
[ ] Unexpected behavior — something is weird but not necessarily wrong
[ ] Performance — program runs but is unexpectedly slow
--- ADDITIONAL NOTES ---
[Anything else that might be relevant — what you were trying to do,
workarounds you found, similar code that DOES work, etc.]
=== END REPORT ===
- Make it minimal — try to cut your code down to the smallest program that still triggers the bug. Remove anything unrelated.
- Include everything — the full source code, the exact command, and the complete output. Don't paraphrase error messages.
- Check KNOWN_ISSUES.md first — run
cat ~/aria/KNOWN_ISSUES.mdto see if the bug is already documented. - Test with the latest code — before reporting, pull the latest changes:
Then try again. The bug might already be fixed.
cd ~/aria git pull ./scripts/build.sh
- One bug per report — if you found three different bugs, send three separate reports.
If you find a bug and want to capture everything quickly, run this in the terminal:
echo "=== ARIA BUG REPORT ===" > bugreport.txt
echo "Date: $(date)" >> bugreport.txt
echo "Git: $(git -C ~/aria log --oneline -1)" >> bugreport.txt
echo "LLVM: $(llvm-config-20 --version)" >> bugreport.txt
echo "OS: $(lsb_release -d -s)" >> bugreport.txt
echo "" >> bugreport.txt
echo "--- SOURCE CODE ---" >> bugreport.txt
cat YOUR_FILE.npk >> bugreport.txt
echo "" >> bugreport.txt
echo "--- COMPILER OUTPUT ---" >> bugreport.txt
~/aria/build/npkc YOUR_FILE.npk -o testprog 2>&1 >> bugreport.txt
echo "" >> bugreport.txt
echo "--- PROGRAM OUTPUT ---" >> bugreport.txt
./testprog 2>&1 >> bugreport.txt
echo "=== END REPORT ===" >> bugreport.txt(Replace YOUR_FILE.npk with your actual filename.)
Then just email us the bugreport.txt file.
You need to use the full path: ~/aria/build/npkc. Or set up the alias described in section 8.
LLVM 20 isn't installed. Run:
sudo apt install -y llvm-20-devInstall liburing:
sudo apt install -y liburing-devMake it executable:
chmod +x ~/aria/scripts/build.sh- Make sure you copied the extension correctly:
If that file doesn't exist, redo step 6.
ls ~/.vscode/extensions/aria-language-0.0.1/package.json - Restart VS Code completely (close all windows, reopen).
- Make sure your file has the
.npkextension.
Make sure your main function prints something or returns a non-zero exit code you can check:
./myprogram
echo $? # shows the exit code (the value you passed to pass())This is likely a compiler bug! Please report it using the bug report template. Include the --emit-llvm output if possible.
cd ~/aria
git pull
./scripts/build.shNitpick includes client libraries for four popular databases. Each uses a C shim to bridge Nitpick's FFI to the database's native C library.
Install the development libraries for the databases you want to use:
# SQLite (embedded, no server needed)
sudo apt install libsqlite3-dev
# PostgreSQL
sudo apt install libpq-dev
# MySQL
sudo apt install libmysqlclient-dev
# Redis
sudo apt install libhiredis-devEach database package lives in aria-packages/packages/aria-<db>/. To build:
cd aria-packages/packages/aria-sqlite
# 1. Build the C shim
cd shim
cc -O2 -shared -fPIC -Wall -o libaria_sqlite_shim.so aria_sqlite_shim.c -lsqlite3
cd ..
# 2. Compile your program that uses the library
npkc my_program.npk -L shim -laria_sqlite_shim -lsqlite3 -o my_program
# 3. Run (shim must be in library path)
LD_LIBRARY_PATH=shim ./my_programfunc:failsafe = NIL(int32:code) { pass(NIL); };
extern "aria_sqlite_shim" {
func:aria_sqlite_open = int32(string:path);
func:aria_sqlite_last_db = int32();
func:aria_sqlite_exec = int32(int32:db, string:sql);
func:aria_sqlite_disconnect = int32(int32:db);
}
func:main = int32() {
int32:db = aria_sqlite_open(":memory:");
int32:d = aria_sqlite_last_db();
aria_sqlite_exec(d, "CREATE TABLE test(id INTEGER PRIMARY KEY, name TEXT)");
int32:d2 = aria_sqlite_last_db();
aria_sqlite_exec(d2, "INSERT INTO test VALUES(1, 'hello')");
int32:d3 = aria_sqlite_last_db();
aria_sqlite_disconnect(d3);
pass(0i32);
};
| Package | API Prefix | System Library | Server Required |
|---|---|---|---|
| aria-sqlite | sqlite_* |
libsqlite3 | No (embedded) |
| aria-postgres | pg_* |
libpq | Yes |
| aria-mysql | mysql_db_* |
libmysqlclient | Yes |
| aria-redis | redis_* |
libhiredis | Yes |
All SQL database packages support parameterized queries to prevent SQL injection.
- Installed build-essential, cmake, git
- Installed llvm-20-dev
- Installed liburing-dev
- Cloned the repository
- Built the compiler with
./scripts/build.sh - Compiled and ran
hello.npk - Installed VS Code syntax highlighting
- Read through
examples/basic/ - Set up the
npkcalias (optional but recommended) - Gave your AI assistant the Nitpick syntax primer prompt
Questions? Problems? Send them our way along with as much detail as you can. Happy testing!