Code Monkey home page Code Monkey logo

rusty-code's Introduction

Rusty Code

Cross-compile

Display source code on screen using Macroquad, built with Rust.

Screenshot

Demo

The application can also run in the browser:

Web demo

Examples

Display a Gist by adding the Gist id as the gist query parameter:

https://ollej.github.io/rusty-code/demo/index.html?gist=7834a1320cbc1bcfb50304f51c19e618

Show URL encoded sourcecode with the code parameter, also use language parameter to set language for syntax highlighting:

https://ollej.github.io/rusty-code/demo/index.html?language=rust&code=fn%20main%28%29%20%7B%0A%20%20%20%20println%21%28%22Hello%20World%21%22%29%3B%0A%7D

Open a Gist

Enter a Gist id:


Show sourcecode

Enter sourcecode:

C C++ Go Java Javascript Perl Python Ruby Rust
<textarea name="code" rows="5" cols="60"></textarea>

Usage

Run from command line to display sourcecode syntax highlighted on screen using the Macroquad game library.

rusty-code 0.6.0
A small tool to display sourcecode files

USAGE:
    rusty-code [OPTIONS]

FLAGS:
    -h, --help       Prints help information
    -V, --version    Prints version information

OPTIONS:
    -c, --code <code>            Code to display, overrides both `filename` and `gist`
    -f, --filename <filename>    Path to sourcecode file to display [default: assets/helloworld.rs]
    -g, --gist <gist>            Gist id to display, if set, will override `filename` option
    -l, --language <language>    Language of the code, if empty defaults to file extension
    -t, --theme <theme>          Path to theme.json file [default: assets/theme.json]

License

Copyright 2022 Olle Wreede, released under the MIT License.

rusty-code's People

Contributors

ollej avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.