diff --git a/content/posts/linux/index.md b/content/posts/linux/index.md index 42a9099cf237fc89c1d9d03e10615292fff66039..2427d7a530dfeb4e528eeab11c13a0e39a7e3f6c 100644 --- a/content/posts/linux/index.md +++ b/content/posts/linux/index.md @@ -9,6 +9,7 @@ tags = ["intro", "linux", "tails", "qubes", "easy"] [extra] blogimage="/gifs/destroy.gif" +blogimagepng="/images/destroy.png" toc=true dateedit=2023-05-10 a4="linux-a4.pdf" diff --git a/content/posts/tails-best/index.md b/content/posts/tails-best/index.md index efb509fd40f9c7e2cfdc276b74dd4f1d0d8ab5bb..bd8756e6e4a96b5b2163a0b24e13f42c86f8ea8b 100644 --- a/content/posts/tails-best/index.md +++ b/content/posts/tails-best/index.md @@ -335,6 +335,7 @@ Hacking is really a way of life. If you are truly committed to your cause, you s <br> +<hr> [^1]: This applies to the IPv4 Internet protocol standard. Caution: In some company networks, this no longer applies! diff --git a/layout/anarsec_article.typ b/layout/anarsec_article.typ index 94d831726bbd75eee0a636c2f6979a735fd94193..67dbe861903144e0add55f43fa9efb722e883d20 100644 --- a/layout/anarsec_article.typ +++ b/layout/anarsec_article.typ @@ -5,32 +5,9 @@ lastediteddate: none, description: none, subtitle: none, + category: none, content ) = { - // format links - show link: it => { - it.body - if type(it.dest) == "string" { - if it.dest.starts-with("https://") or it.dest.starts-with("http://") { - footnote[#it.dest.trim("https://", at: start).trim("http://", at: start)] - } - else if it.dest.starts-with("/glossary#") or it.dest.starts-with("/glossary/#") { - locate(location => { - let elements = query(label(it.dest.trim("/glossary#", at: start).trim("/glossary/#", at: start)), location) - text[#super[†]] - }) - } - else if it.dest.starts-with("/") { - footnote({text[anarsec.guide] + it.dest}) - } - } - else if type(it.dest) == "label" { - locate(location => { - let elements = query(it.dest, location) - text[ (#emph(elements.first().body))] - }) - } - } // format lists set list(marker: ([•], [--])) @@ -48,6 +25,11 @@ text(18pt, subtitle) } } + + #set align(center + bottom) + + #text(18pt)[Series: #category] + ] // inside cover @@ -64,6 +46,40 @@ #outline(indent: 20pt, depth: 3) ] + // format links + show link: it => { + it.body + if type(it.dest) == "string" { + if it.dest == "https://anarsec.guide/recommendations" or it.dest == "/recommendations" { + text[ (#emph()[Recommendations])] + } + else if it.dest.starts-with("/recommendations#") or it.dest.starts-with("/recommendations/#") { + locate(location => { + let elements = query(label(it.dest.trim("/recommendations#", at: start).trim("/recommendations/#", at: start)), location) + text[ (#emph()[Recommendations:] #emph(elements.first().body))] + }) + } + else if it.dest.starts-with("https://") or it.dest.starts-with("http://") { + footnote[#it.dest.trim("https://", at: start).trim("http://", at: start)] + } + else if it.dest.starts-with("/glossary#") or it.dest.starts-with("/glossary/#") { + locate(location => { + let elements = query(label(it.dest.trim("/glossary#", at: start).trim("/glossary/#", at: start)), location) + text[#super[†]] + }) + } + else if it.dest.starts-with("/") { + footnote({text[anarsec.guide] + it.dest}) + } + } + else if type(it.dest) == "label" { + locate(location => { + let elements = query(it.dest, location) + text[ (#emph(elements.first().body))] + }) + } + } + // content set page(numbering: "1") set align(left) @@ -116,3 +132,4 @@ ] ] ] + diff --git a/layout/python/anarsec_article_to_pdf.py b/layout/python/anarsec_article_to_pdf.py index 521c90e40395e17a92ee6726a4931fd9999b127e..cdacaac8d4c481df43564fedebc8a4c5ec86756f 100644 --- a/layout/python/anarsec_article_to_pdf.py +++ b/layout/python/anarsec_article_to_pdf.py @@ -101,8 +101,9 @@ class Converter: description = description_txt_path.open().read() # Copy the front image - front_image = pathlib.Path(workingDirectory) / ("front_image" + pathlib.Path(toml_front_matter['extra']['blogimage']).suffix) - shutil.copy(self.anarsec_root / "static" / toml_front_matter['extra']['blogimage'].removeprefix("/"), front_image) + blogimageid = "blogimagepng" if "blogimagepng" in toml_front_matter["extra"] else "blogimage" + front_image = pathlib.Path(workingDirectory) / ("front_image" + pathlib.Path(toml_front_matter['extra'][blogimageid]).suffix) + shutil.copy(self.anarsec_root / "static" / toml_front_matter['extra'][blogimageid].removeprefix("/"), front_image) # Copy the back image back_image = pathlib.Path(workingDirectory) / "back_image.png" @@ -160,6 +161,7 @@ class Converter: lastediteddate: "{toml_front_matter["extra"]["dateedit"]}", description: "{description}", subtitle: "{toml_front_matter.get("description")}", + category: "{toml_front_matter["taxonomies"]["categories"][0]}", content ) {typst_path.open().read()} diff --git a/static/images/destroy.png b/static/images/destroy.png new file mode 100644 index 0000000000000000000000000000000000000000..5b82d814080cae3677526dc2a1ecf211d94fdd7f Binary files /dev/null and b/static/images/destroy.png differ