This repo contains a web interface for the CWorkbench Compiler project.
This project allows users to run the C compiler C compiler I write through an interactive web interface. Through the interface, you can run C code which is supported by my compiler. The interface allows you to view the output of the code.
The website also contains a brief overview of the compiler and what features it supports.
This project is live at this link. It was deployed using AWS, but is currently deployed using Heroku due to cost considerations.
- C code editor with syntax highlighting
- Executes C programs using my CWorkbench compiler
- Displays program output and return values
- Overview popup describing compiler features
Languages
- HTML/CSS
- JavaScript
Tools / Frameworks
- React.js
- Monaco for the code editor
- Node.js / Express
- Docker
AWS
- ECR
- EC2 Instances
- Elastic Load Balancer
- CloudFormation
You need to have Docker installed to run the project locally.
To run the web interface, follow these steps:
- Clone the repo
- Run the following commands:
docker build -t cworkbench-website .
docker run -e="PORT=<PORT>" -p <PORT>:<PORT> cworkbench-website- Open the website in your browser at
http://localhost:<PORT>
You can change the port to whatever you want by setting the ```PORT`` environment variable, and mapping the desired port. For example:
docker run -e="PORT=3000" -p 3000:3000 cworkbench-website- Write a C program in the code editor
- Press the run button and see the output!
Please note that only a subset of C is currently supported. You can click on the Info button on the website to see more information, and example programs.