Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/strd6/zine
DIY E-Zine and Operating System
https://github.com/strd6/zine
coffeescript html5 mmorpg operating-system punk-rock zine
Last synced: 14 days ago
JSON representation
DIY E-Zine and Operating System
- Host: GitHub
- URL: https://github.com/strd6/zine
- Owner: STRd6
- License: mit
- Created: 2016-12-10T20:21:47.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2019-05-04T20:22:18.000Z (over 5 years ago)
- Last Synced: 2024-09-24T16:19:53.148Z (about 2 months ago)
- Topics: coffeescript, html5, mmorpg, operating-system, punk-rock, zine
- Language: CoffeeScript
- Homepage: https://whimsy.space
- Size: 12.1 MB
- Stars: 26
- Watchers: 3
- Forks: 8
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Zine OS
DIY E-Zine and Operating System
Interfaces
==========FS Interface
------------Read a blob from a path, returns a promise fulfilled with the blob object. The
blob is annotated with the path i.e.: blob.path == pathread: (path) ->
Write a blob to a path, returns a promise that is fulfilled when the write succeeds.
write: (path, blob) ->
Delete a file at a path, returns a promise that is fulfilled when the delete succeeds.
delete: (path) ->
Returns a promise
list: (directoryPath) ->
FileEntry Interface
-------------------path:
size:
type:
updatedAt:FolderEntry Interface
---------------------folder: true
path:Application Interface
---------------------Application objects are views (they have an element, usually a UI window).
element: DOMElement
exit: -> # Exit the app and remove its element from the DOM
send: -> Promise
saved: -> BooleanApps can communicate with each other by sending messages via the `send` method.
Since apps can be running inside iframes or other places all data needs to be
able to survive transit through the structured clone algorithm:
https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers_API/Structured_clone_algorithm`send` returns a promise that is fulfilled with the result of the method or
rejected with an error. The first argument of send is the name of the method to
invoke in the application, the following arguments are the parameters to be
passed to that method.`exit` gives the app a chance to respond and prompt to cancel to prevent losing
unsaved work. (TODO)TODO: Add methods for binding/connecting observables.
TODO: Add methods for connecting streams.System Interface
----------------Apps should be able to read and write to the file system in a simple manner.
readFile: (path) ->
readAsText: (path) ->
readTree: (path) ->
writeFile: (path, blob) ->
deleteFile: (path) ->
The system provides easy ways to launch applications:
# TODO: Better name and arguments
launchAppByAppData: (data) ->