Merge pull request #359 from Hydrazer/master

pkg(husk-1.0.0): add husk
This commit is contained in:
Thomas Hobson 2021-10-09 15:12:25 +13:00 committed by GitHub
commit 0e7775f5d6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 37 additions and 0 deletions

14
packages/husk/1.0.0/build.sh vendored Normal file
View File

@ -0,0 +1,14 @@
#!/usr/bin/env bash
cp ../../haskell/9.0.1/build.sh ./haskell-build.sh
sed -Ei 's/9\.0\.1/8\.10\.7/g' ./haskell-build.sh
source ./haskell-build.sh
# compile Husk from source
git clone -q "https://github.com/barbuz/husk.git"
cd husk
../bin/ghc -O2 Husk
# cleanup
cd ..
rm -f haskell-build.sh

6
packages/husk/1.0.0/environment vendored Normal file
View File

@ -0,0 +1,6 @@
#!/usr/bin/env bash
# haskell and husk path
export PATH=$PWD/bin:$PATH
export HUSK_PATH=$PWD/husk
export LANG=en_US.UTF8

5
packages/husk/1.0.0/metadata.json vendored Normal file
View File

@ -0,0 +1,5 @@
{
"language": "husk",
"version": "1.0.0",
"aliases": []
}

10
packages/husk/1.0.0/run vendored Normal file
View File

@ -0,0 +1,10 @@
#!/usr/bin/env bash
# Store the current path because we'll need it to run the program file
PROGRAM_PATH=$PWD
# For now, Husk can only be run within the folder that has the imported modules
cd $HUSK_PATH
# Run Husk from file in unicode format with the given args
./Husk -uf "${PROGRAM_PATH}/${@}"

1
packages/husk/1.0.0/test.husk vendored Normal file
View File

@ -0,0 +1 @@
"OK

View File

@ -348,6 +348,7 @@ Content-Type: application/json
`golfscript`, `golfscript`,
`groovy`, `groovy`,
`haskell`, `haskell`,
`husk`,
`iverilog`, `iverilog`,
`japt`, `japt`,
`java`, `java`,