commit 483c8249e22f59eddb254511ba8a798a8659cd25 Author: c0dev0id Date: Mon Oct 23 13:19:55 2023 +0200 init diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..903115a --- /dev/null +++ b/Makefile @@ -0,0 +1,65 @@ +all: website fix-permissions + +# Extensions: +# th - template with html code +# ph - page with html code +# pm - page with markdown code +# ps - page with shell code +# pa - page with asciidoctor code + +PH_FILES != find src -type f -name "*.ph" | sed 's|src/||g' +PM_FILES != find src -type f -name "*.pm" | sed 's|src/||g' +PS_FILES != find src -type f -name "*.ps" | sed 's|src/||g' +PA_FILES != find src -type f -name "*.pa" | sed 's|src/||g' + +STATIC_FILES = src/assets + +$(PH_FILES): + echo "Create: src/$@ => www/${@:S/ph/html/}" + cat src/header.th > www/${@:S/ph/html/} + cat src/$@ >> www/${@:S/ph/html/} + cat src/footer.th >> www/${@:S/ph/html/} + +$(PM_FILES): + echo "Create: src/$@ => www/${@:S/pm/html/}" + mkdir -p "$$(dirname www/${@})" + cat src/header.th > www/${@:S/pm/html/} + discount -f fencedcode src/$@ >> www/${@:S/pm/html/} + cat src/footer.th >> www/${@:S/pm/html/} + +$(PS_FILES): + echo "Create: src/$@ => www/${@:S/ps/html/}" + mkdir -p "$$(dirname www/${@})" + cat src/header.th > www/${@:S/ps/html/} + ksh src/$@ >> www/${@:S/ps/html/} + cat src/footer.th >> www/${@:S/ps/html/} + +$(PA_FILES): + echo "Create: src/$@ => www/${@:S/pa/html/}" + mkdir -p "$$(dirname www/${@})" + cat src/header.th > www/${@:S/pa/html/} + asciidoctor -e \ + -r asciidoctor-diagram \ + -a imagesdir=/tmp/adoc-tmp \ + -a stylesheet! \ + -a data-uri \ + -o - src/$@ >> www/${@:S/pa/html/} + cat src/footer.th >> www/${@:S/pa/html/} + +website: prepare copy-static-files $(PH_FILES) $(PM_FILES) $(PS_FILES) $(PA_FILES) + +prepare: + echo "Mkdir: www" + mkdir -p www + +copy-static-files: prepare + rsync -r --partial --delete --out-format="Copy: src/%f => www/%f" $(STATIC_FILES) www/ + +clean: + rm -rf www + +fix-permissions: website + chown -R sdk:www www + chmod -R ug+Xrw www + + diff --git a/README.md b/README.md new file mode 100644 index 0000000..e69de29 diff --git a/src/assets/style.css b/src/assets/style.css new file mode 100644 index 0000000..70227a1 --- /dev/null +++ b/src/assets/style.css @@ -0,0 +1,1529 @@ +body { + font-family:bree serif,sans-serif; + -webkit-font-smoothing:antialiased; + margin: 0 20px +} + +article { + max-width:800px; + margin-left:auto; + margin-right:auto +} + +a { + color:#000; + text-decoration:none +} + +a:hover { + font-weight:600; + text-decoration:underline +} + +.post-ads +{ + margin:50px 0 +} + +.markdown-body +{ + font-size:18px; + max-width:100% +} + +.markdown-body a +{ + + text-decoration:underline; + text-decoration-color:#000 +} + +.markdown-body blockquote +{ + + margin:0; + padding:0 1em; + color:#57606a; + border-left:.25em solid #d0d7de +} + +.markdown-body pre +{ + + padding:12px; + overflow:auto; + background-color:#f6f8fa; + border-radius:8px +} + +.markdown-body code +{ + + padding:.2em .4em; + background-color:#f6f8fa; + border-radius:6px +} + +.markdown-body pre>code +{ + + padding:0; + background-color:inherit; + border:0 +} + +.Chinese .markdown-body +{ + + line-height:200% +} + +.site-date-catalog +{ + + font-size:2rem +} + +.header-title +{ + + font-size:2rem; + font-weight:700; + margin-top:32px; + font-family:bungee shade,sans-serif +} + +.header-title a +{ + + text-decoration:none +} + +.header-subtitle +{ + + color:#666 +} + +.header-items +{ + + margin:10px 0 +} + +.header-item +{ + + margin:0 5px +} + +.header-line +{ + + width:100%; + border-width:2px; + border-color:#482936; + border-style:solid none none none +} + +.lang-switch +{ + + font-weight:600 +} + +#posts-list +{ + + min-height:600px +} + +.posts-line +{ + + font-size:1.2rem; + margin:12px 0 +} + +.posts-categories +{ + + font-size:.8rem; + margin:auto; + text-align:center +} + +.posts-category +{ + + padding:3px 0; + border:#000 2px solid; + border-radius:5px +} + +.site-footer +{ + + margin-top:50px +} + +.site-footer-item +{ + + margin-right:12px +} + +.post-content img +{ + + max-width:100%; + display:block; + margin-right:auto; + margin-top:12px +} + +.post-header +{ + + margin-bottom:50px +} + +.post-title +{ + + font-size:2rem; + font-weight:600 +} + +.post-tags +{ + + display:inline; + font-weight:600; + padding:2px 5px; + margin-right:6px; + border:#000 2px solid; + border-radius:5px +} + +.post-date +{ + + font-weight:800; + font-style:italic +} + +.post-author +{ + + float:right; + font-weight:600 +} + +.page-content +{ + + min-height:60% +} + +.post-content +{ + + margin-bottom:50px +} + +.post-content p +{ + + hyphens:auto; + line-height:1.8; + text-justify:ideographic; + margin-bottom:1em +} + +.related-content +{ + + border-width:3px; + border-style:solid; + border-color:#000; + padding:0 10px; + margin-bottom:50px; + margin-top:100px +} + +.related-content li +{ + + margin:5px 0 +} + +.taxonomy-term +{ + + font-size:3rem +} + +.gallery-img +{ + + text-align:center +} + +.gallery-img span +{ + + text-align:center +} + +.gallery-img-desc +{ + + font-size:.8em; + font-weight:800 +} + +#disqus_thread +{ + + position:relative +} + +#disqus_thread:after +{ + + content:""; + display:block; + height:55px; + width:100%; + position:absolute; + bottom:0; + background:#fff +} + +@media screen and (max-width:600px) +{ + + .header-title,.header-subtitle,.header-items + { + + text-align:center + } + + .posts-line + { + + font-size:16px + } + + .markdown-body + { + + font-size:16px + } + + .post-title + { + + font-size:2rem + } + + .post-content p + { + + letter-spacing:.05em + } + + +} + +@media screen and (max-width:48em) +{ + + .posts-category + { + + display:none + } + + +} + + + + +