diff --git a/engine/update-file-size.sh b/engine/update-file-size.sh index d470935..b0ce241 100755 --- a/engine/update-file-size.sh +++ b/engine/update-file-size.sh @@ -57,7 +57,12 @@ for fic in $filelist; do debug CSS: $csssize total=$(( htmlsize + imgsize + csssize )) # the space is important before the toh total - sizeinfos=$(print -- " $(toh $total) (HTML: $(toh $htmlsize), CSS: $(toh $csssize), IMG: $(toh $imgsize))") + sizeinfos=$(print -- " $(toh $total) (html $(toh $htmlsize), css $(toh $csssize)") + if ((imgsize>0)); then + sizeinfos="$sizeinfos, img $(toh $imgsize))" + else + sizeinfos="$sizeinfos)" + fi print -- $sizeinfos perl -pi -e 's#(
)[^<]*(
)#$1'"$sizeinfos"'$2#' $fic done diff --git a/project.el b/project.el index 4e06f07..6f6a01a 100644 --- a/project.el +++ b/project.el @@ -65,6 +65,16 @@ "" "")) +(defun gen-permalink (output-file) + "Given the output-file generate a permalink" + (format "%s%s" + websiteorigin + (replace-regexp-in-string ".*/_site" "" output-file))) + +(defun gen-org-src (permalink) + "Given a permalink generate the path to the asssociated .org source file" + (replace-regexp-in-string "\.html$" ".org" permalink)) + (defun org-blog-preamble (info) "Pre-amble for whole blog." (concat @@ -85,13 +95,10 @@ (car date)))) " on " (format " Yann Esposito's blog" websiteorigin) - (let ((permalink (format "%s%s" - websiteorigin - (replace-regexp-in-string ".*/_site" "" - (plist-get info :output-file))))) + (let ((permalink (gen-permalink (plist-get info :output-file)))) (concat " - " - (let ((orgfile (replace-regexp-in-string "\.html$" ".org" permalink))) + (let ((orgfile (gen-org-src permalink))) (format " source" orgfile)) " - " (format " §permalink" permalink))) @@ -112,7 +119,7 @@ (let ((keywords (split-string keywords ",\s*"))) (format " %s" (mapconcat (lambda (k) - (format "#%s" k)) + (format "#%s" k)) (cl-sort keywords 'string-lessp :key 'downcase) " ")))) @@ -151,7 +158,7 @@ "RSS" "" " (" - " validate)" + "validate)" "")) (generated-date (format "
%s
" @@ -164,20 +171,26 @@ "Spacemacs %s, " "Org Mode %s" "") - emacs-version spacemacs-version org-version))) + emacs-version spacemacs-version org-version)) + (website-code + "Website source code") + (org-src (gen-org-src (gen-permalink (plist-get info :output-file)))) + (org-src-link (format "%s" org-src org-src))) (concat "" (mapconcat (lambda (entry) (when (cdr entry) (format "" (car entry) (cdr entry)))) - `(("Author" . ,author) - ("Date" . ,date) - ("Keywords" . ,keywords) - ("RSS" . ,rss) - ("Size" . ,size) - ("Generated" . ,generated-date) - ("Generated with" . ,generated-with)) + `(("author" . ,author) + ("date" . ,date) + ("tags" . ,keywords) + ("rss" . ,rss) + ("size" . ,size) + ("gen-date" . ,generated-date) + ("get-with" . ,generated-with) + ("website-src" . ,website-code) + ("org-file" . ,org-src-link)) " ") "
%s%s
")) "" diff --git a/project.el.sig b/project.el.sig index 57fa15c..0f47ff5 100644 Binary files a/project.el.sig and b/project.el.sig differ diff --git a/src/css/mk.css b/src/css/mk.css index 62dcd69..774af73 100644 --- a/src/css/mk.css +++ b/src/css/mk.css @@ -3,15 +3,19 @@ */ /* Fonts */ :root { - --lh: 22px; + --lh: 20px; } body { - font-size: 18px; + font-size: 16px; font-family: sans-serif; line-height: var(--lh); min-height: 100vh; } +footer { + font-size: 14px; + font-family: monospace; +} code { font-size: 15px; } @@ -214,21 +218,6 @@ figure, .figure { .underline { text-decoration: underline; } -#h { - float: left; -} -#labels { - width: 100%; - text-align: right; -} -#labels label { - text-decoration: underline; - cursor: pointer; - font-style: italic; -} -label + pre { - margin-top: 0; -} /* COLORS */ :root { @@ -240,21 +229,21 @@ label + pre { --b1: #b0bac7; --b2: #ECEFF4; --b3: #fff; - --y: #a98d50; - --o: #aa6550; - --r: #b85a64; - --m: #af53b0; - --v: #846f93; - --b: #5679a4; - --c: #4c8493; - --g: #728b5c; + --y: #c18600; + --o: #d84100; + --r: #e62729; + --m: #ec0085; + --v: #6c71c4; + --b: #0095ff; + --c: #00b0a3; + --g: #879a00; --bg: var(--b3); --rbg: var(--b2); --fg0: var(--b0); --fg: var(--b02); --rfg: #000; - --hl: var(--c); + --hl: var(--b); } img { @@ -272,7 +261,6 @@ h1, h2, h3, h4, h5, h6 { a { color: var(--hl); } - b, strong, i, em { color: var(--rfg); } @@ -288,11 +276,15 @@ h1:before, h2:before, h3:before, h4:before, h5:before, h6:before { .metas, .metas a, .metas a:visited { color: var(--fg0); } - nav a, nav a:visited { color: var(--fg); } -ol > li:before, pre::after,pre::before,hr:after, label, label a, label a:visited { +a:hover, .metas a:hover, nav a:hover +{ + color: #fff; + background: var(--hl); +} +ol > li:before, pre::after,pre::before,hr:after { color: var(--fg0); } diff --git a/src/index.org b/src/index.org index 1371386..a954870 100644 --- a/src/index.org +++ b/src/index.org @@ -62,9 +62,5 @@ priority: javascript, no web-font, not too much CSS magic, not much images or really compressed one. -I talk about more details [[file:./posts/new-blog.org][here]]. - - -#+begin_export html -[Valid RSS] -#+end_export +If you are interested about technical details behind this website, take a +look [[file:./posts/new-blog.org][here]].