File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -197,13 +197,33 @@ run() {
197197 elif [[ ${FILE#* .} == go ]]; then
198198 if [[ $COMPILE == true ]]; then
199199 go build -o " ${FILE%% .* } .out" " $FILE "
200- if [[ $PERSISTENT != true ]]; then
201- rm " ${FILE%% .* } .out"
202- fi
203200 else
204201 go run " $FILE "
205202 fi
203+ if [[ $PERSISTENT != true ]]; then
204+ rm " ${FILE%% .* } .out"
205+ fi
206206
207+ elif [[ ${FILE#* .} == pl ]]; then
208+ perl " $FILE "
209+
210+ elif [[ ${FILE#* .} == lua ]]; then
211+ lua " $FILE "
212+
213+ elif [[ ${FILE#* .} == rb ]]; then
214+ ruby " $FILE "
215+
216+ elif [[ ${FILE#* .} == hs ]]; then
217+ if [[ $DEBUG == true ]]; then
218+ ghci " $FILE "
219+ fi
220+ if [[ $COMPILE == true ]]; then
221+ ghc --make " $FILE "
222+ else
223+ runghc " $FILE "
224+ fi
225+
226+
207227 else
208228 _ERROR_UFTC_
209229 _EXIT_
@@ -232,10 +252,14 @@ for arg in "$@"; do
232252 echo " ${yellow} >>${white} Bash-Script"
233253 echo " ${yellow} >>${white} Javascript ${cyan} [${white} with ${green} debug${white} support${cyan} ]"
234254 echo " ${yellow} >>${white} Golang"
255+ echo " ${yellow} >>${white} Perl"
256+ echo " ${yellow} >>${white} Lua"
257+ echo " ${yellow} >>${white} Ruby"
258+ echo " ${yellow} >>${white} Haskell ${cyan} [${white} with ${green} debug${white} support${cyan} ]"
235259 echo
236260 ;;
237261
238- * " .c" | * " .cpp" | * " .py" | * " .rs" | * " .java" | * " .sh" | * " .js" | * " .go" )
262+ * " .c" | * " .cpp" | * " .py" | * " .rs" | * " .java" | * " .sh" | * " .js" | * " .go" | * " .pl " | * " .lua " | * " .rb " | * " .hs " )
239263 FILE_LOCATION=$arg
240264 if [[ ! -f $FILE_LOCATION ]]; then
241265 _ERROR_UFTC_
You can’t perform that action at this time.
0 commit comments