The purpose of this repository is to serve as a template for new Lingua Franca (LF) projects that use the C target. The goal is to provide a large number of examples and documentation specific to the C target so as to guide AI assistants that use files in a local context to guide their responses, including those using RAG (Retrieval Augmented Generation).
To use this, at the curated-c homepage, select "Use this template" to create a new repository.
This repository contains the following:
-
A
contextdirectory with many examples of Lingua Franca (LF) programs for the C target. -
An
lfdocsdirectory with a snapshot of the Lingua Franca documentation re-rendered as static HTML pages. The entry point is lfdocs/index.html. -
A
scriptsdirectory with utilities used to update the context. -
A
Makefilefor formatting LF files, cleaning build artifacts, and updating the context. -
A
srcdirectory with an example LF program to help users get started.
Run the following to update context information from the original sources:
make update
Then commit the changes. If you want to update only the context (example LF programs) or lfdocs (the Lingua Franca documentation), the following commands will individually perform these updates:
make update-context
make update-lfdocs
If you have created your own repository from this template, and you later wish to update the context information to the latest template data, you can do this with the following steps:
Add the template as a "remote" and merge its history into your own:
-
Add the template as a remote:
git remote add template https://github.com/lf-lang/curated-c.git -
Fetch the latest changes:
git fetch template -
Merge the changes: Since the histories are unrelated, you must use the following flag:
git merge template/main --allow-unrelated-histories -
Resolve conflicts: If any template files have been modified in your new repo, you will need to manually resolve merge conflicts before committing.