Toy brainf**k interpreter; example app that can be modified without restarting
Go to file
Kartik K. Agaram e11906700e Merge template-live-editor 2024-03-10 22:35:39 -07:00
assets set up documentation before publishing repo 2023-01-16 22:38:07 -08:00
examples first programs working 2023-01-16 20:59:44 -08:00
0000-freewheeling-start Merge template-live-editor 2023-04-16 11:20:19 -07:00
0001-on wire up mouse move handler 2023-12-26 08:28:23 -08:00
0002-Debug_animations_in_progress debug animations 2023-11-11 10:00:54 -08:00
0002-Num_panels_horizontal Merge template-live-editor 2023-04-16 11:20:19 -07:00
0003-Num_panels_vertical Merge template-live-editor 2023-04-16 11:20:19 -07:00
0003-refresh_debug_animations debug animations 2023-11-11 10:00:54 -08:00
0004-Margin Merge template-live-editor 2023-04-16 11:20:19 -07:00
0004-on.update debug animations 2023-11-11 10:00:54 -08:00
0005-Font_size Merge template-live-editor 2023-04-16 11:20:19 -07:00
0005-animate debug animations 2023-11-11 10:00:54 -08:00
0006-Cursor Merge template-live-editor 2023-04-16 11:20:19 -07:00
0006-loiter debug animations 2023-11-11 10:00:54 -08:00
0007-Title_font Merge template-live-editor 2023-04-16 11:20:19 -07:00
0007-save_callstack debug animations 2023-11-11 10:00:54 -08:00
0008-Data_title_text Merge template-live-editor 2023-04-16 11:20:19 -07:00
0008-Debug_animation_period debug animations 2023-11-11 10:00:54 -08:00
0009-panel_bounds Merge template-live-editor 2023-04-16 11:20:19 -07:00
0010-create_editor Merge template-live-editor 2023-12-29 15:29:54 -08:00
0011-In Merge template-live-editor 2023-04-16 11:20:19 -07:00
0012-Code Merge template-live-editor 2023-04-16 11:20:19 -07:00
0013-Data Merge template-live-editor 2023-04-16 11:20:19 -07:00
0014-Out Merge template-live-editor 2023-04-16 11:20:19 -07:00
0015-on.draw Merge template-live-editor 2023-04-16 11:20:19 -07:00
0016-draw_title Merge template-live-editor 2023-04-16 11:20:19 -07:00
0017-on.mouse_press Merge template-live-editor 2023-04-16 11:20:19 -07:00
0018-create_editor_panel Merge template-live-editor 2023-12-29 15:29:54 -08:00
0019-on.text_input Merge template-live-editor 2023-04-16 11:20:19 -07:00
0020-editor_to_string Merge template-live-editor 2023-04-16 11:20:19 -07:00
0021-map Merge template-live-editor 2023-04-16 11:20:19 -07:00
0022-draw_editor_panel Merge template-live-editor 2023-04-16 11:20:19 -07:00
0023-on.initialize Merge template-live-editor 2023-04-16 11:20:19 -07:00
0024-draw_data Merge template-live-editor 2023-04-16 11:20:19 -07:00
0025-on.key_release Merge template-live-editor 2023-04-16 11:20:19 -07:00
0026-on.keychord_press Merge template-live-editor 2023-04-16 11:20:19 -07:00
0027-on.mouse_release Merge template-live-editor 2023-04-16 11:20:19 -07:00
0028-eval Merge template-live-editor 2023-04-16 11:20:19 -07:00
LICENSE.txt add a license 2022-05-16 18:51:28 -07:00
Manual_tests.md Merge text0 2023-12-07 01:22:19 -08:00
MemoryReferenceInfo.lua.0 remove some memory leaks from rendered fragments 2022-06-10 11:16:41 -07:00
MemoryReferenceInfo.lua.unused clean up memory leak experiments 2022-06-10 13:46:59 -07:00
README.md Merge template-live-editor 2024-03-10 22:35:39 -07:00
app.lua Merge text0 2024-02-04 17:45:48 -08:00
bf.lua first programs working 2023-01-16 20:59:44 -08:00
button.lua bugfix :( 2023-12-18 21:39:01 -08:00
default_map suggest a default layout for freewheeling apps 2023-11-11 10:31:25 -08:00
edit.lua Merge text0 2024-02-16 21:33:22 -08:00
file.lua audit all asserts 2023-11-18 11:32:01 -08:00
json.lua forgot to add json.lua 2022-05-15 14:36:25 -07:00
keychord.lua support for num pad 2023-07-07 18:40:12 -07:00
live.lua rename a function to be more specific 2023-12-15 15:17:28 -08:00
main.lua Merge template-live-editor 2024-01-15 03:25:21 -08:00
nativefs.lua cleaner API for file-system access 2023-08-30 19:04:06 -07:00
reference.md Merge text0 2024-02-04 17:45:48 -08:00
search.lua Merge text0 2024-01-15 02:33:22 -08:00
select.lua Merge lines.love 2024-01-15 01:38:38 -08:00
test.lua show another detail on test failure 2023-01-20 21:48:49 -08:00
text.lua Merge text0 2024-02-08 02:58:10 -08:00
text_tests bugfix: clear selection when clicking above or below lines 2023-09-20 13:39:29 -07:00
text_tests.lua Merge text0 2024-02-08 02:58:10 -08:00
undo.lua fix a couple of asserts missed in the recent audit 2023-12-09 09:22:45 -08:00

README.md

Toy interpreter for Brainf@@k

https://en.wikipedia.org/wiki/Brainfuck

screenshot

Example program for trying out driver.love, a programming environment for modifying programs live, without restarting them.

Some reference documentation on how to create your own apps.

This repo is an example of a Freewheeling App, designed above all to be easy to run, easy to modify and easy to share.

Getting started

Install LÖVE. It's just a 5MB download, open-source and extremely well-behaved.

Run the app using LÖVE.

Hacking

To modify it live without restarting the app each time, download the driver app.

screenshot of driver app showing overview of this repo

If the app being modified by the driver lives in a .love file, your changes will go into the save directory. If it lives in a directory (like this repo), your changes will go straight into the same directory.

Keyboard shortcuts

Press f4 to evaluate a program.

Within each editor panel:

  • ctrl+f to find patterns within a file
  • ctrl+c to copy, ctrl+x to cut, ctrl+v to paste
  • ctrl+z to undo, ctrl+y to redo
  • ctrl+= to zoom in, ctrl+- to zoom out, ctrl+0 to reset zoom
  • alt+right/alt+left to jump to the next/previous word, respectively
  • mouse drag or shift + movement to select text, ctrl+a to select all

Exclusively tested so far with a US keyboard layout. If you use a different layout, please let me know if things worked, or if you found anything amiss: http://akkartik.name/contact

Known issues

Mirrors and Forks

This repo is a fork of lines.love, an editor for plain text where you can also seamlessly insert line drawings. Its immediate upstream is the template repo for freewheeling apps. Updates to it can be downloaded from the following mirrors:

Further forks are encouraged. If you show me your fork, I'll link to it here.

Feedback

Most appreciated.