Skip to content

A Turing-Complete, not-really-modern, slow script language for no purpose

Notifications You must be signed in to change notification settings

sanj0/edgy-script

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Foo

Edgy Script

Edgy Script: a modern, slow, barely-documented programming language for no purpose.

This projects contains three modules:

  • e80, the interpreter and native provider API
  • esrun, the script that runs a given ES-Script
  • esdk, which is a collection of java classes that provide a sdk for Edgy Scripts

Examples

  1. The classical Hello World:
use stdio;

print("Hello World!\n");
  1. A stupidly long version of the Hello World:
use stdio;

var hello = "Hello";
var world = "World";

print(hello + " " + world + "!\n");
# better: printf "%s %s!\n", hello, world
// should not make a real performance difference though
  1. An enhanced Hello World with more features:
use stdio;

print("What is your name? ");
var name = $string[input()];

print("Hello World, " + name + " here!\n");
  1. Enhanced Hello World with Easteregg
use stdio;
 
printf("What is your name? ");
var name = $[input()];
 
if name == "Stormtrooper":
    print("These are not the droids you are looking for!");
else:
    print("Hello World, " + name + " here!\n")

Code inside $TYPE[] is evaluated at runtime as Edgy Script code, and optionally being cast to the non-bligtory TYPE, input is a function of stdio that returns user input upon pressing ENTER.
Comments are either made by putting // or # in front of a line or /* and */ at the beginning of lines to have everythign in between (inclusively) commented.
A ; at the end of a line is allowed and considered good practice but not needed.

How to install Edgy Script

On Linux and MacOS, you can use one of the install scripts, on Windows (not supported yet), follow these steps:

  1. Make sure that git, maven and Java are installed properly on your system
  2. Clone the repo
    • type git clone https://www.github.com/edgelord314/edgy-script into a CLI
  3. Build e80 and the esdk using maven
    • cd into the repo (cd edgy-script)
    • cd into the e80 project (cd e80)
    • build it using maven (mvn clean install)
    • cd into the sdk project (cd ../esdk)
    • build it using maven (still mvn clean install)
  4. Run a script using esrun/esrun.sh
    • cd into the esrun project (cd ../esrun)
    • run the script using the esrun script (./esrun.sh path-to-file.et)

About

A Turing-Complete, not-really-modern, slow script language for no purpose

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published