From 18afb488c0ca73d4512c0dcbc2d7da5393e22cac Mon Sep 17 00:00:00 2001 From: fischerq Date: Sat, 3 Jun 2023 17:03:27 +0000 Subject: [PATCH] Add repl config --- .replit | 14 ++++++++++++++ compile.sh | 11 +++++++++++ index.html | 28 ++++++++++++++++++++++++++++ replit.nix | 8 ++++++++ runner.sh | 7 +++++++ 5 files changed, 68 insertions(+) create mode 100644 .replit create mode 100644 compile.sh create mode 100644 index.html create mode 100644 replit.nix create mode 100644 runner.sh diff --git a/.replit b/.replit new file mode 100644 index 0000000..cff9cc4 --- /dev/null +++ b/.replit @@ -0,0 +1,14 @@ +compile = ["sh", "compile.sh"] +#compile = ["pdflatex", "-halt-on-error", "book/book.tex"] +run = ["sh", "runner.sh"] + +hidden = ["*.aux", "*.log", "index.html", "runner.sh", "nohup.out"] + +[languages.latex] +pattern = "**/*.tex" + +[languages.latex.languageServer] +start = "texlab" + +[nix] +channel = "stable-21_11" \ No newline at end of file diff --git a/compile.sh b/compile.sh new file mode 100644 index 0000000..48ea7a2 --- /dev/null +++ b/compile.sh @@ -0,0 +1,11 @@ +#!/bin/sh + +set -x + +cd book +#ls +#cat makefile +#make -f makefile make_pdf +pdflatex -halt-on-error book.tex +biber +pdflatex -halt-on-error book.tex \ No newline at end of file diff --git a/index.html b/index.html new file mode 100644 index 0000000..a063ec4 --- /dev/null +++ b/index.html @@ -0,0 +1,28 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/replit.nix b/replit.nix new file mode 100644 index 0000000..edff70e --- /dev/null +++ b/replit.nix @@ -0,0 +1,8 @@ +{ pkgs }: { + deps = [ + pkgs.texlive.combined.scheme-full + pkgs.httplz + pkgs.texlab + pkgs.biber + ]; +} \ No newline at end of file diff --git a/runner.sh b/runner.sh new file mode 100644 index 0000000..2ccd07e --- /dev/null +++ b/runner.sh @@ -0,0 +1,7 @@ +PID_FILE=/tmp/httplz.pid +kill $(cat $PID_FILE) +sleep 0.1 + +nohup httplz -l . & +sleep 0.1 +echo $! > $PID_FILE \ No newline at end of file