From 9cd7083a056e24bdb3ef4b31038e5c99599a4e75 Mon Sep 17 00:00:00 2001 From: Tyrel Souza Date: Thu, 24 Nov 2022 15:02:42 +0000 Subject: [PATCH] Initial commit --- Dockerfile | 20 ++++++++++++++++++++ code/helloworld.hla | 8 ++++++++ start.sh | 4 ++++ 3 files changed, 32 insertions(+) create mode 100644 Dockerfile create mode 100644 code/helloworld.hla create mode 100755 start.sh diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..f198d8d --- /dev/null +++ b/Dockerfile @@ -0,0 +1,20 @@ +FROM i686/ubuntu + +RUN apt update +RUN apt install -y build-essential wget vim zsh + +RUN mkdir -p /code +WORKDIR /code + +RUN wget https://www.plantation-productions.com/Webster/HighLevelAsm/HLAv2.16/linux.hla.tar.gz --no-check-certificate + +RUN tar -xzvf linux.hla.tar.gz +RUN mv usr/hla /usr/ + +RUN cp /usr/hla/hla /bin +RUN cp /usr/hla/hlaparse /bin +RUN rm -rf usr + +RUN rm linux.hla.tar.gz + +CMD ["/bin/zsh"] diff --git a/code/helloworld.hla b/code/helloworld.hla new file mode 100644 index 0000000..a6b6c18 --- /dev/null +++ b/code/helloworld.hla @@ -0,0 +1,8 @@ +program helloWorld; +#include( "stdlib.hhf" ); + +begin helloWorld; + + stdout.put( "Hello, world", nl ); + +end helloWorld; diff --git a/start.sh b/start.sh new file mode 100755 index 0000000..a27c797 --- /dev/null +++ b/start.sh @@ -0,0 +1,4 @@ +#!/bin/bash + +docker build . -t workspace +docker run --rm -it --mount=type=bind,source="$(pwd)"/code,target=/code workspace