diff --git a/build-js.sh b/build-js.sh index c24b0cb..ab7940c 100755 --- a/build-js.sh +++ b/build-js.sh @@ -85,7 +85,7 @@ done if [ "$neochan" == "yes" ] ; then set +e - for exe in lessc coffee ; do + for exe in lessc tsc ; do which $exe &> /dev/null if [ "$?" != "0" ] ; then echo "$exe not installed"; @@ -98,10 +98,10 @@ if [ "$neochan" == "yes" ] ; then echo initfile "$neochan_js_outfile" - for f in ./contrib/js/neochan/*.coffee ; do - echo "compile $f" - coffee -cs < "$f" > "$f.js" - done + + echo "compile typescript" + tsc ./contrib/js/neochan/*.ts + for f in ./contrib/js/neochan/*.js ; do mini "$f" "$neochan_js_outfile" done diff --git a/contrib/js/neochan/.gitignore b/contrib/js/neochan/.gitignore index 5e8935c..4c43fe6 100644 --- a/contrib/js/neochan/.gitignore +++ b/contrib/js/neochan/.gitignore @@ -1 +1 @@ -*.coffee.js \ No newline at end of file +*.js \ No newline at end of file diff --git a/contrib/js/neochan/init.coffee.js b/contrib/js/neochan/init.coffee.js deleted file mode 100644 index 49caa98..0000000 --- a/contrib/js/neochan/init.coffee.js +++ /dev/null @@ -1,5 +0,0 @@ -// Generated by CoffeeScript 1.11.1 -(function() { - - -}).call(this); diff --git a/contrib/js/neochan/init.coffee b/contrib/js/neochan/postform.ts similarity index 100% rename from contrib/js/neochan/init.coffee rename to contrib/js/neochan/postform.ts diff --git a/contrib/templates/neochan/postform.mustache b/contrib/templates/neochan/postform.mustache index f135674..aacee01 100644 --- a/contrib/templates/neochan/postform.mustache +++ b/contrib/templates/neochan/postform.mustache @@ -8,9 +8,9 @@ - files ( bool, do we allow attachments ? ) - csrf ( csrf token ) }} -
+ {{{csrf}}} - +
@@ -32,7 +32,7 @@ @@ -77,14 +77,6 @@ -
- +