Add Prolog

This commit is contained in:
1computer1 2019-03-15 20:44:37 -04:00
parent b13857e7a4
commit 41d4500ce6
4 changed files with 18 additions and 0 deletions

View file

@ -75,6 +75,7 @@ Options are optionally set in `options`, which is a semicolon-delimited list of
- `pas` Pascal (FPC 3.0.4) - `pas` Pascal (FPC 3.0.4)
- `php` PHP (PHP 7.3.3) - `php` PHP (PHP 7.3.3)
- `pl` Perl (Perl 5.28.1) - `pl` Perl (Perl 5.28.1)
- `prolog` Prolog (SWI-Prolog 8.1.2)
- `py` Python (CPython 3.7.2, CPython 2.7.16) - `py` Python (CPython 3.7.2, CPython 2.7.16)
- `2` runs Python 2 instead of Python 3 - `2` runs Python 2 instead of Python 3
- `rb` Ruby (Ruby 2.6.2) - `rb` Ruby (Ruby 2.6.2)

4
docker/prolog/Dockerfile Normal file
View file

@ -0,0 +1,4 @@
FROM swipl
LABEL author="1Computer1"
COPY run.sh /var/run/

2
docker/prolog/run.sh Normal file
View file

@ -0,0 +1,2 @@
echo "$1" > program.pl
swipl --quiet program.pl

11
src/languages/prolog.js Normal file
View file

@ -0,0 +1,11 @@
const Language = require('../struct/Language');
class Prolog extends Language {
constructor() {
super('prolog', {
aliases: ['prolog']
});
}
}
module.exports = Prolog;