leaps

module
Version: v0.9.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 22, 2021 License: MIT

README

Leaps

godoc for jeffail/leaps goreportcard for jeffail/leaps

Leaps is a service for collaboratively editing your local files over a web UI, using operational transforms to ensure zero-collision synchronization across any number of editing clients.

WARNING: This project is no longer actively maintained.

Screenshot

Run

Simply navigate to a directory you want to share, run leaps, open the hosted page (default http://localhost:8080) in your browser and direct any friends on your LAN to the same page. You can now collaboratively edit any documents in that directory.

Your files will be written to in the background as you edit. If you aren't using version control, or simply want extra protection, you can run leaps in safe mode with the --safe flag. In safe mode any changes you make will be placed in a .leaps_cot.json file, which you can then apply to your files once you are happy by running with the --commit flag.

Build/test commands from the UI

When writing code it sucks to have to leave the editor for running tests, linters or builds. However, allowing the internet to run arbitrary commands on the host machine is a recipe for disaster.

Instead, leaps allows you to specify pre-written commands using the -cmd flag, which are then available for clients to trigger asynchronously while they edit. Results are broadcast to all connected users, so you can all see the outcome as a team.

For example, leaps -cmd "golint ./..." -cmd "go build ./cmd/leaps" gives users both a linter and a build command that they can trigger on your machine.

API

Leaps can also be used as a library, with implementations of accessors for various document hosting solutions and plugable authentication layers, allowing you to build your own services to suit many service architectures.

Leaps server components are implemented in Golang, and has a client implemented in JavaScript that can currently be used with ACE, CodeMirror and Textarea editors.

To read more about the service library components and find examples check out the godocs.

To read about the JavaScript client check out the README.

Install

Leaps is a single binary, with no runtime dependencies. Just download a package for your OS from the latest releases page.

From homebrew

brew install leaps
leaps -h

Build with Go

go get github.com/Jeffail/leaps/cmd/...
leaps -h

System compatibility

OS Status
OSX x86_64 Supported, tested
Linux x86 Supported
Linux x86_64 Supported, tested
Linux ARMv5 Builds
Linux ARMv7 Supported, tested
Windows x86 Builds
Windows x86_64 Builds

Contributing and customizing

Contributions are very welcome, just fork and submit a pull request.

Contact

Ashley Jeffs

Directories

Path Synopsis
cmd
leaps
Package main - This package creates the leaps command line binary.
Package main - This package creates the leaps command line binary.
lib
acl
Package acl - Contains solutions for introducing Access Control Layers to a leaps service.
Package acl - Contains solutions for introducing Access Control Layers to a leaps service.
api
Package api - Contains network API implementations.
Package api - Contains network API implementations.
api/events
Package events - Contains string constants and structs for API event and error types.
Package events - Contains string constants and structs for API event and error types.
api/io
Package io - Contains network api.Emitter implementations for io types.
Package io - Contains network api.Emitter implementations for io types.
audit
Package audit - Implementations of operational transform auditors responsible for taking a stream of operational transform and creating useful features from that stream.
Package audit - Implementations of operational transform auditors responsible for taking a stream of operational transform and creating useful features from that stream.
binder
Package binder - Defines the binder type, used for managing multiple clients of a single document, ensuring that operational transforms received are ordered and dispatched across all other clients.
Package binder - Defines the binder type, used for managing multiple clients of a single document, ensuring that operational transforms received are ordered and dispatched across all other clients.
curator
Package curator - Defines the type used to interact with leaps documents.
Package curator - Defines the type used to interact with leaps documents.
store
Package store - Contains solutions for Reading/Writing leaps documents, all store types should implement the Storage interface as this is used by leaps to read and write documents.
Package store - Contains solutions for Reading/Writing leaps documents, all store types should implement the Storage interface as this is used by leaps to read and write documents.
text
Package text - Contains logic for manipulating text based operational transforms, applying them to documents and caching them within state machines for easy management.
Package text - Contains logic for manipulating text based operational transforms, applying them to documents and caching them within state machines for easy management.
util
Package util - Various miscellaneous utilities used throughout leaps lib.
Package util - Various miscellaneous utilities used throughout leaps lib.
util/service
Package util provides a few bootstrapping utilities for golang services, and a consistent API to wrap third parties libraries for things such as stats aggregation and logging.
Package util provides a few bootstrapping utilities for golang services, and a consistent API to wrap third parties libraries for things such as stats aggregation and logging.
util/service/log
Package log - Some utilities for logging and stats aggregation/pushing.
Package log - Some utilities for logging and stats aggregation/pushing.
util/service/metrics
Package metrics - Create a type for aggregating and propagating metrics to various services based on configuration.
Package metrics - Create a type for aggregating and propagating metrics to various services based on configuration.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL