Compare commits

..

12 Commits

Author SHA1 Message Date
Thomas Hobson 0c4e206d03
Merge pull request #319 from Brikaa/r-language
pkg(rscript-4.1.1): Added R 4.1.1
2021-09-13 01:37:40 +12:00
Thomas Hobson 575ddf2dc0
Merge branch 'master' into r-language 2021-09-13 01:24:39 +12:00
Thomas Hobson dc20ec2bda
ci: Rebuild API container if required when testing 2021-09-13 01:09:38 +12:00
Thomas Hobson c3a33f2c8b
Merge pull request #321 from engineer-man/HexF-patch-2
ci: Build the repo-builder container if it was modified in a PR
2021-09-13 01:02:46 +12:00
Thomas Hobson d630b5ebe7
Build repo-builder if required 2021-09-13 01:01:59 +12:00
Thomas Hobson 1566b49574
Build repo-builder if required 2021-09-13 01:00:54 +12:00
Thomas Hobson 2fa49797fb
Merge pull request #320 from engineer-man/dependabot/npm_and_yarn/cli/axios-0.21.2
build(deps): bump axios from 0.21.1 to 0.21.2 in /cli
2021-09-13 00:57:27 +12:00
dependabot[bot] 252987932c
build(deps): bump axios from 0.21.1 to 0.21.2 in /cli
Bumps [axios](https://github.com/axios/axios) from 0.21.1 to 0.21.2.
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/master/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v0.21.1...v0.21.2)

---
updated-dependencies:
- dependency-name: axios
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-09-12 12:57:09 +00:00
Thomas Hobson 4367aae723
Merge pull request #317 from Brikaa/mono-error
pkg(mono-6.12.0): redirect mono compile errors to stderr
2021-09-13 00:53:37 +12:00
Brikaa 864e94739f Add rscript to readme 2021-09-12 14:39:56 +02:00
Brikaa 1250cf213a pkg(rscript-4.1.1): Added R 4.1.1 2021-09-12 14:38:57 +02:00
Brikaa b3772c9502 pkg(mono-6.12.0): redirect mono error to stderr 2021-09-10 15:34:53 +02:00
13 changed files with 75 additions and 25 deletions

View File

@ -55,7 +55,9 @@ jobs:
run: | run: |
PACKAGES=$(jq '.[]' -r ${HOME}/files.json | awk -F/ '{ print $2 "-" $3 }' | sort -u) PACKAGES=$(jq '.[]' -r ${HOME}/files.json | awk -F/ '{ print $2 "-" $3 }' | sort -u)
echo "Packages: $PACKAGES" echo "Packages: $PACKAGES"
docker run -v "${{ github.workspace }}:/piston" docker.pkg.github.com/engineer-man/piston/repo-builder:latest --no-server $PACKAGES docker pull docker.pkg.github.com/engineer-man/piston/repo-builder:latest
docker build -t repo-builder repo
docker run -v "${{ github.workspace }}:/piston" repo-builder --no-server $PACKAGES
ls -la packages ls -la packages
- name: Upload package as artifact - name: Upload package as artifact
@ -89,7 +91,9 @@ jobs:
run: | run: |
ls -la ls -la
docker run -v $(pwd)'/repo:/piston/repo' -v $(pwd)'/packages:/piston/packages' -d --name repo docker.pkg.github.com/engineer-man/piston/repo-builder --no-build docker run -v $(pwd)'/repo:/piston/repo' -v $(pwd)'/packages:/piston/packages' -d --name repo docker.pkg.github.com/engineer-man/piston/repo-builder --no-build
docker run --network container:repo -v $(pwd)'/data:/piston' -e PISTON_LOG_LEVEL=DEBUG -e 'PISTON_REPO_URL=http://localhost:8000/index' -d --name api docker.pkg.github.com/engineer-man/piston/api docker pull docker.pkg.github.com/engineer-man/piston/api
docker build -t piston-api api
docker run --network container:repo -v $(pwd)'/data:/piston' -e PISTON_LOG_LEVEL=DEBUG -e 'PISTON_REPO_URL=http://localhost:8000/index' -d --name api piston-api
echo Waiting for API to start.. echo Waiting for API to start..
docker run --network container:api appropriate/curl -s --retry 10 --retry-connrefused http://localhost:2000/api/v2/runtimes docker run --network container:api appropriate/curl -s --retry 10 --retry-connrefused http://localhost:2000/api/v2/runtimes

View File

@ -33,7 +33,9 @@ jobs:
run: | run: |
PACKAGES=$(jq '.[]' -r ${HOME}/files.json | awk -F/ '{ print $2 "-" $3 }' | sort -u) PACKAGES=$(jq '.[]' -r ${HOME}/files.json | awk -F/ '{ print $2 "-" $3 }' | sort -u)
echo "Packages: $PACKAGES" echo "Packages: $PACKAGES"
docker run -v "${{ github.workspace }}:/piston" docker.pkg.github.com/engineer-man/piston/repo-builder:latest --no-server $PACKAGES docker pull docker.pkg.github.com/engineer-man/piston/repo-builder:latest
docker build -t repo-builder repo
docker run -v "${{ github.workspace }}:/piston" repo-builder --no-server $PACKAGES
ls -la packages ls -la packages
- name: Upload Packages - name: Upload Packages
@ -73,4 +75,4 @@ jobs:
file: index file: index
tag: pkgs tag: pkgs
overwrite: true overwrite: true
file_glob: true file_glob: true

View File

@ -13,7 +13,7 @@ RUN apt-get update && \
libncurses6 libncurses5 libedit-dev libseccomp-dev rename procps python3 \ libncurses6 libncurses5 libedit-dev libseccomp-dev rename procps python3 \
libreadline-dev libblas-dev liblapack-dev libpcre3-dev libarpack2-dev \ libreadline-dev libblas-dev liblapack-dev libpcre3-dev libarpack2-dev \
libfftw3-dev libglpk-dev libqhull-dev libqrupdate-dev libsuitesparse-dev \ libfftw3-dev libglpk-dev libqhull-dev libqrupdate-dev libsuitesparse-dev \
libsundials-dev && \ libsundials-dev libpcre2-dev && \
rm -rf /var/lib/apt/lists/* rm -rf /var/lib/apt/lists/*
RUN sed -i '/en_US.UTF-8/s/^# //g' /etc/locale.gen && locale-gen RUN sed -i '/en_US.UTF-8/s/^# //g' /etc/locale.gen && locale-gen

41
cli/package-lock.json generated
View File

@ -9,7 +9,7 @@
"version": "1.0.0", "version": "1.0.0",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"axios": "^0.21.1", "axios": "^0.21.2",
"chalk": "^4.1.0", "chalk": "^4.1.0",
"minimatch": "^3.0.4", "minimatch": "^3.0.4",
"nocamel": "^1.0.2", "nocamel": "^1.0.2",
@ -37,11 +37,11 @@
} }
}, },
"node_modules/axios": { "node_modules/axios": {
"version": "0.21.1", "version": "0.21.2",
"resolved": "https://registry.npmjs.org/axios/-/axios-0.21.1.tgz", "resolved": "https://registry.npmjs.org/axios/-/axios-0.21.2.tgz",
"integrity": "sha512-dKQiRHxGD9PPRIUNIWvZhPTPpl1rf/OxTYKsqKUDjBwYylTvV7SjSHJb9ratfyzM6wCdLCOYLzs73qpg5c4iGA==", "integrity": "sha512-87otirqUw3e8CzHTMO+/9kh/FSgXt/eVDvipijwDtEuwbkySWZ9SBm6VEubmJ/kLKEoLQV/POhxXFb66bfekfg==",
"dependencies": { "dependencies": {
"follow-redirects": "^1.10.0" "follow-redirects": "^1.14.0"
} }
}, },
"node_modules/balanced-match": { "node_modules/balanced-match": {
@ -115,11 +115,22 @@
} }
}, },
"node_modules/follow-redirects": { "node_modules/follow-redirects": {
"version": "1.13.3", "version": "1.14.3",
"resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.13.3.tgz", "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.14.3.tgz",
"integrity": "sha512-DUgl6+HDzB0iEptNQEXLx/KhTmDb8tZUHSeLqpnjpknR70H0nC2t9N73BK6fN4hOvJ84pKlIQVQ4k5FFlBedKA==", "integrity": "sha512-3MkHxknWMUtb23apkgz/83fDoe+y+qr0TdgacGIA7bew+QLBo3vdgEN2xEsuXNivpFy4CyDhBBZnNZOtalmenw==",
"funding": [
{
"type": "individual",
"url": "https://github.com/sponsors/RubenVerborgh"
}
],
"engines": { "engines": {
"node": ">=4.0" "node": ">=4.0"
},
"peerDependenciesMeta": {
"debug": {
"optional": true
}
} }
}, },
"node_modules/get-caller-file": { "node_modules/get-caller-file": {
@ -297,11 +308,11 @@
} }
}, },
"axios": { "axios": {
"version": "0.21.1", "version": "0.21.2",
"resolved": "https://registry.npmjs.org/axios/-/axios-0.21.1.tgz", "resolved": "https://registry.npmjs.org/axios/-/axios-0.21.2.tgz",
"integrity": "sha512-dKQiRHxGD9PPRIUNIWvZhPTPpl1rf/OxTYKsqKUDjBwYylTvV7SjSHJb9ratfyzM6wCdLCOYLzs73qpg5c4iGA==", "integrity": "sha512-87otirqUw3e8CzHTMO+/9kh/FSgXt/eVDvipijwDtEuwbkySWZ9SBm6VEubmJ/kLKEoLQV/POhxXFb66bfekfg==",
"requires": { "requires": {
"follow-redirects": "^1.10.0" "follow-redirects": "^1.14.0"
} }
}, },
"balanced-match": { "balanced-match": {
@ -366,9 +377,9 @@
"integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==" "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw=="
}, },
"follow-redirects": { "follow-redirects": {
"version": "1.13.3", "version": "1.14.3",
"resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.13.3.tgz", "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.14.3.tgz",
"integrity": "sha512-DUgl6+HDzB0iEptNQEXLx/KhTmDb8tZUHSeLqpnjpknR70H0nC2t9N73BK6fN4hOvJ84pKlIQVQ4k5FFlBedKA==" "integrity": "sha512-3MkHxknWMUtb23apkgz/83fDoe+y+qr0TdgacGIA7bew+QLBo3vdgEN2xEsuXNivpFy4CyDhBBZnNZOtalmenw=="
}, },
"get-caller-file": { "get-caller-file": {
"version": "2.0.5", "version": "2.0.5",

View File

@ -5,7 +5,7 @@
"main": "index.js", "main": "index.js",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"axios": "^0.21.1", "axios": "^0.21.2",
"chalk": "^4.1.0", "chalk": "^4.1.0",
"minimatch": "^3.0.4", "minimatch": "^3.0.4",
"nocamel": "^1.0.2", "nocamel": "^1.0.2",

View File

@ -1,13 +1,20 @@
#!/bin/bash #!/bin/bash
check_errors () {
grep -q 'error [A-Z]\+[0-9]\+:' check.txt && cat check.txt 1>&2 || cat check.txt
rm check.txt
}
case "${PISTON_LANGUAGE}" in case "${PISTON_LANGUAGE}" in
csharp) csharp)
rename 's/$/\.cs/' "$@" # Add .cs extension rename 's/$/\.cs/' "$@" # Add .cs extension
csc -out:out *.cs csc -out:out *.cs > check.txt
check_errors
;; ;;
basic) basic)
rename 's/$/\.vb/' "$@" # Add .vb extension rename 's/$/\.vb/' "$@" # Add .vb extension
vbnc -out:out *.vb vbnc -out:out *.vb > check.txt
check_errors
;; ;;
*) *)
echo "How did you get here? (${PISTON_LANGUAGE})" echo "How did you get here? (${PISTON_LANGUAGE})"

16
packages/rscript/4.1.1/build.sh vendored Executable file
View File

@ -0,0 +1,16 @@
#!/bin/bash
PREFIX=$(realpath $(dirname $0))
mkdir build
cd build
curl https://cloud.r-project.org/src/base/R-4/R-4.1.1.tar.gz -o R.tar.gz
tar xzf R.tar.gz --strip-components 1
./configure --prefix="$PREFIX" --with-x=no
make -j$(nproc)
make install -j$(nproc)
cd ../
rm -rf build

1
packages/rscript/4.1.1/environment vendored Normal file
View File

@ -0,0 +1 @@
export PATH=$PWD/bin:$PATH

5
packages/rscript/4.1.1/metadata.json vendored Normal file
View File

@ -0,0 +1,5 @@
{
"language": "rscript",
"version": "4.1.1",
"aliases": ["r"]
}

2
packages/rscript/4.1.1/run vendored Normal file
View File

@ -0,0 +1,2 @@
#/bin/bash
Rscript "$@"

1
packages/rscript/4.1.1/test.r vendored Normal file
View File

@ -0,0 +1 @@
cat('OK')

View File

@ -356,6 +356,7 @@ Content-Type: application/json
`python2`, `python2`,
`raku`, `raku`,
`rockstar`, `rockstar`,
`rscript`,
`ruby`, `ruby`,
`rust`, `rust`,
`scala`, `scala`,

View File

@ -8,7 +8,8 @@ RUN apt-get update && apt-get install -y unzip autoconf build-essential libssl-d
util-linux pciutils usbutils coreutils binutils findutils grep libncurses5-dev \ util-linux pciutils usbutils coreutils binutils findutils grep libncurses5-dev \
libncursesw5-dev python3-pip libgmp-dev libmpfr-dev python2 libffi-dev gfortran\ libncursesw5-dev python3-pip libgmp-dev libmpfr-dev python2 libffi-dev gfortran\
libreadline-dev libblas-dev liblapack-dev libpcre3-dev libarpack2-dev libfftw3-dev \ libreadline-dev libblas-dev liblapack-dev libpcre3-dev libarpack2-dev libfftw3-dev \
libglpk-dev libqhull-dev libqrupdate-dev libsuitesparse-dev libsundials-dev && \ libglpk-dev libqhull-dev libqrupdate-dev libsuitesparse-dev libsundials-dev \
libbz2-dev liblzma-dev libpcre2-dev && \
ln -sf /bin/bash /bin/sh && \ ln -sf /bin/bash /bin/sh && \
rm -rf /var/lib/apt/lists/* && \ rm -rf /var/lib/apt/lists/* && \
update-alternatives --install /usr/bin/python python /usr/bin/python3.7 2 update-alternatives --install /usr/bin/python python /usr/bin/python3.7 2
@ -17,4 +18,3 @@ ADD entrypoint.sh mkindex.sh /
ENTRYPOINT ["bash","/entrypoint.sh"] ENTRYPOINT ["bash","/entrypoint.sh"]
CMD ["--no-build"] CMD ["--no-build"]