Freebasic
FreeBASIC programming language skill for AI code assistantsFrom its SKILL.md
npx -y skills add woyxiang/skills --skill freebasicAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
SKILL.md
4.2 KB, ~1.2k tokens by cl100k_base, as published. Nobody here has run it
FreeBASIC Skill
FreeBASIC is a free/open source, BASIC compiler for Linux, Windows, and DOS.
Detection
This skill activates when working with FreeBASIC code or projects. Watch for:
File extensions: .bas, .bi
Comments:
' FreeBASIC comment
Language markers:
Dim,Var,Function,Sub,Print,Input,If,For,While#if,#define,#include(preprocessor)End Function,End Sub,End Type- Compiler options:
-lang fb,-lang qb,-lang fblite - Meta-statements:
$Dynamic,$Static,$Include
Quick Reference
Keywords
| Keyword | Description | Doc |
|---|---|---|
| Dim, Var | Declare variables | types.md |
| Function, Sub | Define procedures | procedures.md |
| If, Then, Else | Conditional execution | control-flow.md |
| For, While, Do | Loops | control-flow.md |
| Print, Input | Console I/O | basics.md |
| Open, Close, Get, Put | File I/O | file-io.md |
| String, Len, Mid | String operations | strings.md |
| Screen, Circle, Line | Graphics | graphics.md |
API Search
Use the search script to find keywords:
python scripts/search-api.py "print to screen" --top 5
python scripts/search-api.py --name "Print" -v
python scripts/search-api.py --json "array dimension"
python scripts/search-api.py --list-categories
Topic Routing
Language Fundamentals
| Task | Doc |
|---|---|
| Hello World, first program | basics.md |
| Variables and data types | types.md |
| Operators and expressions | operators.md |
| Control flow (if, for, while) | control-flow.md |
| Functions and subs | procedures.md |
| Arrays and dynamic memory | arrays.md |
| Strings and string functions | strings.md |
Data Types
| Task | Doc |
|---|---|
| Integer, Double, Boolean | types.md |
| User-defined types (UDT) | user-defined-types.md |
| Pointers and memory | pointers.md |
| Type casting and conversion | types.md |
Standard Library
| Task | Doc |
|---|---|
| File I/O (Open, Print#, Get, Put) | file-io.md |
| Console I/O (Print, Input, Color) | basics.md |
| Date and time functions | date-time.md |
| Math functions (Abs, Sin, Cos) | math.md |
| Memory allocation | pointers.md |
Graphics & UI
| Task | Doc |
|---|---|
| Screen modes and drawing | graphics.md |
| User input (mouse, keyboard) | graphics.md |
| Images and sprites | graphics.md |
Advanced Topics
| Task | Doc |
|---|---|
| Preprocessor directives | preprocessor.md |
| Threading and synchronization | threading.md |
| Error handling (On Error) | error-handling.md |
| Compiler options and dialects | compiler.md |
| QB migration guide | compiler.md |
Syntax Examples
Hello World
Print "Hello, World!"
Variables
Dim As Integer x = 10
Dim As Double pi = 3.14159
Dim As String name = "FreeBASIC"
Arrays
Dim array(0 To 9) As Integer
Dim matrix(1 To 3, 1 To 3) As Double
ReDim Preserve array(0 To 20)
Control Flow
If x > 0 Then
Print "positive"
ElseIf x < 0 Then
Print "negative"
Else
Print "zero"
End If
For i As Integer = 1 To 10
Print i
Next
Do While condition
' ...
Loop
Functions
Function Add(ByVal a As Integer, ByVal b As Integer) As Integer
Return a + b
End Function
Sub SayHello(name As String)
Print "Hello, " + name + "!"
End Sub
Dependencies
- FreeBASIC compiler (fbc)
- Python 3.10+ for search scripts
See Also
What ships with it: 24 files
2986.3 KB alongside SKILL.md, 5 of them executable
data/
- api-bm25.json2003.1 KB
- api.json924.8 KB
scripts/
- build-index.pyruns3.3 KB
- extract-api.pyruns9.2 KB
- search-api.pyruns6.1 KB
tests/
- test_api_search.pyruns2.9 KB
- test_structure.pyruns3.3 KB
- arrays.md1.7 KB
- basics.md1.8 KB
- compiler.md1.6 KB
- control-flow.md1.4 KB
- date-time.md1.7 KB
- error-handling.md1.5 KB
- file-io.md2.2 KB
- graphics.md2.6 KB
- math.md2.0 KB
- operators.md2.0 KB
- pointers.md2.2 KB
- preprocessor.md2.2 KB
- procedures.md2.4 KB
- strings.md2.0 KB
- threading.md1.9 KB
- types.md2.6 KB
- user-defined-types.md1.7 KB