mirror of
https://github.com/alex-s168/website.git
synced 2025-09-10 01:05:07 +02:00
c
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -1,7 +1,6 @@
|
||||
build
|
||||
*.html
|
||||
*.pdf
|
||||
res/badges
|
||||
build.ninja
|
||||
.ninja_log
|
||||
.ninja_deps
|
||||
|
47
config.py
47
config.py
@@ -1,4 +1,4 @@
|
||||
import os.path
|
||||
import os
|
||||
|
||||
gen = """
|
||||
rule regen
|
||||
@@ -19,10 +19,17 @@ rule curl
|
||||
command = curl $url > $out
|
||||
|
||||
rule cp
|
||||
command = cp $in $out
|
||||
command = cp $flags $in $out
|
||||
|
||||
rule cpdir
|
||||
command = rm -rf $out && cp -rf $in $outdir
|
||||
|
||||
rule runclean
|
||||
command = ninja -t clean && rm -rf build
|
||||
command = rm -rf build && ninja -t clean
|
||||
|
||||
rule ttf2woff
|
||||
command = fonttools ttLib.woff2 compress $in -o $out
|
||||
|
||||
|
||||
build build/badges.txt: badges_list common.typ
|
||||
|
||||
@@ -37,8 +44,11 @@ pages = [
|
||||
"index.typ",
|
||||
"compiler-pattern-matching.typ",
|
||||
"article-favicon.typ",
|
||||
"article-gpu-arch-1.typ",
|
||||
]
|
||||
|
||||
fonts = [x for x in os.listdir("./res/fonts/")]
|
||||
|
||||
variants = [
|
||||
{
|
||||
"suffix": ".min.pdf",
|
||||
@@ -82,22 +92,43 @@ if os.path.isfile("build/badges.txt"):
|
||||
badge = badge.split("\t")
|
||||
user = badge[0]
|
||||
url = badge[1]
|
||||
tg = "res/badges/" + user
|
||||
tg = "build/res/badges/" + user
|
||||
web_targets.append(tg)
|
||||
gen += "\n"
|
||||
gen += "build "+tg+": "
|
||||
if user == "alex":
|
||||
gen += "cp res/badge.png\n"
|
||||
gen += "cp res/badge.png | build/res/_.txt\n"
|
||||
else:
|
||||
gen += "curl\n"
|
||||
gen += "curl | build/res/_.txt\n"
|
||||
gen += " url = "+url+"\n"
|
||||
|
||||
for font in fonts:
|
||||
font = font.replace(".ttf", "")
|
||||
tg = f"build/res/{font}.woff2"
|
||||
web_targets.append(tg)
|
||||
gen += "\n"
|
||||
gen += f"build {tg} : ttf2woff res/fonts/{font}.ttf | build/res/_.txt\n"
|
||||
|
||||
gen += "\n"
|
||||
gen += "build build/index.html : cp build/index.typ.desktop.html\n"
|
||||
web_targets.append("build/index.html")
|
||||
|
||||
gen += "\n"
|
||||
gen += "default " + " ".join(web_targets) + "\n"
|
||||
gen += """
|
||||
build build/res/_.txt : cpdir res | res/_.txt
|
||||
outdir = build
|
||||
"""
|
||||
web_targets.append("build/res/_.txt")
|
||||
|
||||
gen += """
|
||||
build web: phony """+ " ".join(web_targets) +"""
|
||||
|
||||
rule pub_cmd
|
||||
command = rsync -avz build root@195.26.251.204:/srv/http/alex
|
||||
pool = console
|
||||
build pub: pub_cmd | web
|
||||
|
||||
default web
|
||||
"""
|
||||
|
||||
with open("build.ninja", "w") as f:
|
||||
f.write(gen)
|
||||
|
30
pages/article-gpu-arch-1.typ
Normal file
30
pages/article-gpu-arch-1.typ
Normal file
@@ -0,0 +1,30 @@
|
||||
#import "../common.typ": *
|
||||
#import "../simple-page-layout.typ": *
|
||||
#import "../core-page-style.typ": *
|
||||
#import "../components/header.typ": rev-and-authors
|
||||
|
||||
#simple-page(
|
||||
gen-table-of-contents: true,
|
||||
[GPU architecture: SIMD - Alexander Nutz]
|
||||
)[
|
||||
|
||||
#section[
|
||||
#title[GPU Architecture: Compute Cores]
|
||||
|
||||
#sized-p(small-font-size)[
|
||||
#rev-and-authors((people.alex,))
|
||||
]
|
||||
]
|
||||
|
||||
#if is-web {section[
|
||||
Note that the #gen-min-pdf-link[PDF Version] of this page might look a bit better styling wise.
|
||||
]}
|
||||
|
||||
#section[
|
||||
= Introduction
|
||||
GPUs consists of multiple (commonly 64) compute units.
|
||||
|
||||
]
|
||||
|
||||
|
||||
]
|
5
pub.sh
5
pub.sh
@@ -1,5 +0,0 @@
|
||||
set -e
|
||||
ninja
|
||||
#scp -r build/* root@195.26.251.204:/srv/http/alex
|
||||
rsync -avz build root@195.26.251.204:/srv/http/alex
|
||||
#scp -r res/* root@195.26.251.204:/srv/http/alex/res
|
@@ -1 +0,0 @@
|
||||
f256bdf8d1d8100be843a5f76ccfb5f0cb7315f98d075ae583b29916740e58ab res/badges/alex
|
@@ -1 +0,0 @@
|
||||
9aecefadc2369798121567c27b4599cb92dd8bd56d926f1544c3ddd860762605 res/badges/ote
|
@@ -1 +0,0 @@
|
||||
90a0093089d2ae940639aca8ca4dd86f0b7a20fd5b12adb313480b8b1868bc2b res/badges/syn
|
BIN
res/fonts/DejaVuMathTeXGyre.ttf
Normal file
BIN
res/fonts/DejaVuMathTeXGyre.ttf
Normal file
Binary file not shown.
BIN
res/fonts/DejaVuSans-Bold.ttf
Normal file
BIN
res/fonts/DejaVuSans-Bold.ttf
Normal file
Binary file not shown.
BIN
res/fonts/DejaVuSans-BoldOblique.ttf
Normal file
BIN
res/fonts/DejaVuSans-BoldOblique.ttf
Normal file
Binary file not shown.
BIN
res/fonts/DejaVuSans-ExtraLight.ttf
Normal file
BIN
res/fonts/DejaVuSans-ExtraLight.ttf
Normal file
Binary file not shown.
BIN
res/fonts/DejaVuSans-Oblique.ttf
Normal file
BIN
res/fonts/DejaVuSans-Oblique.ttf
Normal file
Binary file not shown.
BIN
res/fonts/DejaVuSans.ttf
Normal file
BIN
res/fonts/DejaVuSans.ttf
Normal file
Binary file not shown.
BIN
res/fonts/DejaVuSansMono-Bold.ttf
Normal file
BIN
res/fonts/DejaVuSansMono-Bold.ttf
Normal file
Binary file not shown.
BIN
res/fonts/DejaVuSansMono-BoldOblique.ttf
Normal file
BIN
res/fonts/DejaVuSansMono-BoldOblique.ttf
Normal file
Binary file not shown.
BIN
res/fonts/DejaVuSansMono-Oblique.ttf
Normal file
BIN
res/fonts/DejaVuSansMono-Oblique.ttf
Normal file
Binary file not shown.
BIN
res/fonts/DejaVuSansMono.ttf
Normal file
BIN
res/fonts/DejaVuSansMono.ttf
Normal file
Binary file not shown.
BIN
res/fonts/DejaVuSerif-Bold.ttf
Normal file
BIN
res/fonts/DejaVuSerif-Bold.ttf
Normal file
Binary file not shown.
BIN
res/fonts/DejaVuSerif-BoldItalic.ttf
Normal file
BIN
res/fonts/DejaVuSerif-BoldItalic.ttf
Normal file
Binary file not shown.
BIN
res/fonts/DejaVuSerif-Italic.ttf
Normal file
BIN
res/fonts/DejaVuSerif-Italic.ttf
Normal file
Binary file not shown.
BIN
res/fonts/DejaVuSerif.ttf
Normal file
BIN
res/fonts/DejaVuSerif.ttf
Normal file
Binary file not shown.
Reference in New Issue
Block a user