Minor script changes

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Minor script changes

danilafoxpro

I have some minor changes on my local copy of Luan. Changes described in order:

  1. Consistent usage of `$LUANHOME`, removed reliance on current directory.
  2. Made Luan build and install fine (on Linux) without requiring launching it via sudo. Only asks to elevate privileges if installation failed.
  3. Minor spelling mistake fix.
Could they be implemented upstream?

diff -r 1828ed4ee75d scripts/build-luan.sh
--- a/scripts/build-luan.sh Wed Mar 09 15:40:12 2022 -0700
+++ b/scripts/build-luan.sh Fri Mar 11 22:00:01 2022 +0100
@@ -9,7 +9,7 @@

find . -name *.class -delete

-. classpath.sh
+. $LUANHOME/classpath.sh

cd $LUANHOME/src
javac -classpath $CLASSPATH `find . -name *.java`
@@ -28,6 +28,6 @@
VERSION=`java -classpath $CLASSPATH luan.Luan classpath:luan/version.luan`
tar -cf luan-$VERSION.tar luan

-luan/install.sh
+luan/install.sh || sudo luan/install.sh

echo done
diff -r 1828ed4ee75d src/luan/modules/http/Http.luan
--- a/src/luan/modules/http/Http.luan Wed Mar 09 15:40:12 2022 -0700
+++ b/src/luan/modules/http/Http.luan Fri Mar 11 22:00:01 2022 +0100
@@ -200,7 +200,7 @@
local call = Http.error_priority(e)
local err = e.get_stack_trace_string()
logger[call](err.."\n"..trim(java_request.rawHead).."\n")
- local msg = "Internel Server Error\n\n"..err
+ local msg = "Internal Server Error\n\n"..err
return Response.errorResponse( Status.INTERNAL_SERVER_ERROR, msg )
end
Reply | Threaded
Open this post in threaded view
|

Re: Minor script changes

fschmidt
Administrator
This is fine, you can commit this.