aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJaro <jarorutjes07@gmail.com>2024-09-05 15:31:27 +0200
committerJaro <jarorutjes07@gmail.com>2024-09-05 15:31:27 +0200
commit9629228f27b9585a83053f028952945f156cefbc (patch)
tree28f7fff4ca54f8df07a9b606e5fd427659551dc3
parent441e03b613064552d8ab11a6a7eacf6d66d5b999 (diff)
parentc129df28338644c43b0a202ff71e1ff61107e765 (diff)
Merge branch 'master' of github.com:lonkaars/crepe-docs into jaro/project-plan
-rw-r--r--.editorconfig2
-rw-r--r--.gitignore2
-rw-r--r--.vscode/settings.json29
-rw-r--r--contributing.md16
-rw-r--r--makefile3
-rw-r--r--projdoc.cls5
-rw-r--r--time.txt2
-rwxr-xr-xtime2tex.py17
-rw-r--r--timerep.tex11
9 files changed, 85 insertions, 2 deletions
diff --git a/.editorconfig b/.editorconfig
index 1bd7da9..cb52f84 100644
--- a/.editorconfig
+++ b/.editorconfig
@@ -5,7 +5,7 @@ indent_style = tab
end_of_line = lf
insert_final_newline = true
-[*.{md,yml}]
+[*.{md,yml,py}]
indent_style = space
indent_size = 2
diff --git a/.gitignore b/.gitignore
index f087c7f..efdebb8 100644
--- a/.gitignore
+++ b/.gitignore
@@ -31,3 +31,5 @@
!img/*.pdf
img/*.puml.pdf
+# generated files
+time.tex
diff --git a/.vscode/settings.json b/.vscode/settings.json
index 478283a..72f0e6b 100644
--- a/.vscode/settings.json
+++ b/.vscode/settings.json
@@ -13,5 +13,32 @@
"name": "latexmk",
"tools": [ "latexmk" ]
}
- ]
+ ],
+ "files.exclude": {
+ "*.aux": true,
+ "*.bbl": true,
+ "*.bcf": true,
+ "*.blg": true,
+ "*.fdb_latexmk": true,
+ "*.fls": true,
+ "*.out": true,
+ "*.run.xml": true,
+ "*.synctex.gz": true,
+ "*.toc": true,
+ "*.synctex(busy)": true,
+ "*.lof": true,
+ "*.lot": true,
+ "*.glo": true,
+ "*.gls": true,
+ "*.glg": true,
+ "*.ist": true,
+ "*.acn": true,
+ "*.pytxcode": true,
+ "*.glstex": true,
+ "*.cb": true,
+ "*.cb2": true,
+ "*.d": true,
+ "*.nav": true,
+ "*.snm": true
+ }
}
diff --git a/contributing.md b/contributing.md
index ab14b71..770d02e 100644
--- a/contributing.md
+++ b/contributing.md
@@ -15,6 +15,22 @@ other document.
- Images should be placed in the img/ folder
- Labels and bibliography keys should only consist of characters from the
following set: `[a-z0-9:-]` (lower-case, numbers, colon, dash).
+- Quotes are opened with the tilde (<code>`</code>)
+
+# Banned practices
+
+- **Using `\newpage`**
+
+ Widows and orphans are handled by LaTeX. If you want to prevent a page break
+ from occurring between two paragraphs, use the `\noparbreak` command at the
+ end of the first paragraph. For larger chunks, the `\needspace{<length>}`
+ command should be used instead.
+- **Using `\href`**
+
+ Add the source in sources.bib and cite this source instead.
+- **Using `\textbf` or `\textit` to emphasize**
+
+ Use `\emph`, single quotes or an em dash (`---`) instead.
# References
diff --git a/makefile b/makefile
index 0802e01..6c234ba 100644
--- a/makefile
+++ b/makefile
@@ -9,3 +9,6 @@ LATEXMKFLAGS += -interaction=nonstopmode
plantuml -tpdf $<
mv $*.pdf $@
+%.tex: %.txt
+ ./time2tex.py $< > $@
+
diff --git a/projdoc.cls b/projdoc.cls
index b43fe56..c6abaca 100644
--- a/projdoc.cls
+++ b/projdoc.cls
@@ -259,3 +259,8 @@
\fitimg{\includegraphics[scale=0.6]{#1}}%
}
+% prevent page break between two paragraphs
+\makeatletter
+\newcommand\noparbreak{\par\nobreak\@afterheading}
+\makeatother
+
diff --git a/time.txt b/time.txt
index 6a592e0..c80fabf 100644
--- a/time.txt
+++ b/time.txt
@@ -6,6 +6,8 @@ loek: 2024-09-04 1h30m repository scaffolding / latex example code
loek: 2024-09-04 50m poc / dynamic library linking test example
loek: 2024-09-04 45m repository scaffolding / visual studio code latex configuration
loek: 2024-09-04 20m repository scaffolding / visual studio code cmake configuration
+loek: 2024-09-05 15m repository scaffolding / additional latex contributing guidelines
+loek: 2024-09-05 1h40m project meeting
# vim:ft=cfg
diff --git a/time2tex.py b/time2tex.py
new file mode 100755
index 0000000..3244b8f
--- /dev/null
+++ b/time2tex.py
@@ -0,0 +1,17 @@
+#!/bin/python3
+import sys
+
+
+if __name__ == "__main__":
+ if len(sys.argv) != 2:
+ print("usage: time2tex <input>")
+ exit(1)
+
+ input_file = sys.argv[1]
+ content = ""
+ with open(input_file, "r") as file:
+ content = file.read()
+ parsed = parse(content)
+
+
+
diff --git a/timerep.tex b/timerep.tex
new file mode 100644
index 0000000..dfde932
--- /dev/null
+++ b/timerep.tex
@@ -0,0 +1,11 @@
+\documentclass{projdoc}
+\input{meta.tex}
+
+\title{Time Report}
+
+\begin{document}
+
+AHOIHJSAIDHOISAJDSAJDJAOIS
+
+\end{document}
+