Skip to content

Regal-Internet-Brothers/virtualos

Repository files navigation

virtualos

Description

This is an experimental module for the Monkey programming language, meant to provide an alternative frontend (And implementation) of 'os'. Most notably, this provides an implementation for JavaScript based targets. For example, the HTML5 target, and the unofficial 'jstool' target (Including supported derivatives).

Features:

  • Full API compatibility with the official 'os' module.
  • Compatibility with the 'brl' module's 'os' equivalents.
  • Support for multiple backends. (C++, JavaScript, etc; several configuration options)
  • Usable as a 1:1 replacement for 'os' when provided with Monkey's official "os.cpp" file.
  • Fully working file-system based on HTML5's file-storage and ECMAScript's object mechanics.
  • Stable file-path semantics. (Used heavily in WebCC)
  • Configurable behavior for 'Execute'. (User-defined; native code)
  • Format-independent file-storage. (Abstraction layer)
  • Persistent storage between executions. (HTML5 file storage; demo available)
  • Optional experimental and/or unsafe extensions; storage mechanics, file downloads, etc.
  • Support for "virtual directory structures" using this tool.
  • Self-contained; no external module requirements unless requested.
  • Native conversion routines between (Binary) strings, base64, and raw ArrayBuffers.

Purpose and Current Usage

This is still an experimental product. Some behavior is untested (JS codebase), and may perform differently from BRL's implementation. Use this module at your own risk.

This was created in tandem with the 'WebCC' project, an on-going port of Monkey's compiler to modern web browsers. That project is primarily powered by this module, so therefore, any changes made to this module need to behave with that compiler.

Because this needs to be used with 'WebCC', dependencies to unofficial modules, such as 'regal', will remain optional.

TODO:

  • Optimize storage performance with JavaScript: Properties vs. Relational Lookups.

About

A semi-experimental module for Monkey, implementing 'os' and a functional file-system on unsupported platforms. (HTML5)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published