diff --git a/src/archive.org b/src/archive.org index 339686f..7c60a56 100644 --- a/src/archive.org +++ b/src/archive.org @@ -4,5 +4,5 @@ #+begin_archive @@html:
  • @@ @@html:@@ 2019-07-12: @@html:@@ [[file:posts/draft-professional-lessons-and-opinions.org][Professional Lessons and Opinions]] @@html:@@ @@html:
  • @@ -@@html:
  • @@ @@html:@@ 2019-07-05: @@html:@@ [[file:posts/2019-07-04-org-publish.org][org-publish]] @@html:@@ @@html:
  • @@ +@@html:
  • @@ @@html:@@ 2019-07-07: @@html:@@ [[file:posts/2019-07-04-static-org-publish.org][Static blog with org-mode]] @@html:@@ @@html:
  • @@ #+end_archive diff --git a/src/assets/css/minimalist.css b/src/assets/css/minimalist.css index 6f24098..ab452d4 100644 --- a/src/assets/css/minimalist.css +++ b/src/assets/css/minimalist.css @@ -6,13 +6,25 @@ body { font-family: menlo, monospace; font-size: 15px; line-height: 20px; - max-width: 50em; - margin: 0 auto; + margin: 0; + padding: 0; + border: 0; hyphens: auto; -webkit-hyphens: auto; -moz-hyphens:auto; -ms-hyphens:auto; } +#preamble,#postamble { + opacity: 0.5; +} +#preamble:focus,#postamble:focus, +#preamble:hover,#postamble:hover { + opacity:1; +} +#content,.content { + max-width: 50em; + margin: 0 auto; +} h1, h2, h3, h4, h5, h6, pre, code, blockquote, ol, ul, @@ -48,7 +60,6 @@ hr { line-height: 0; overflow: hidden; border: 0; - margin: 20px 0; } hr:after { content: "----------------------------------------------------------------------------------------------------"; @@ -117,32 +128,49 @@ ol > li:before { /* colors */ -img { max-width: 100%; - max-height: 800px; - margin: 20px auto; } -footer { font-size: 0.8em; opacity: 0.5; } -footer:hover { opacity: 1; } -navigation { font-weight: bold; - font-family: menlo, monospace; - } -navigation a { display: inline-block; - padding: .5ex 1ex; - margin-right: 1em; - } -.article-date { opacity: 0.5; font-size: 0.8; } - -table { width: 100%; - margin: 20px 0; - border-collapse: collapse; - border: solid 1px; } -td, th { height: 20px; - padding: 0 10px; - text-align: left; - vertical-align: middle; - border-right: solid 1px; - border-left: solid 1px; - } - +img { + max-width: 100%; + max-height: 800px; + margin: 20px auto; +} +footer { + font-size: 0.8em; +} +.article-date { + opacity: 0.5; + font-size: 0.8; +} +table { + width: 100%; + margin: 20px 0; + border-collapse: collapse; + border: solid 1px; +} +td, th { + height: 20px; + padding: 0 10px; + text-align: left; + vertical-align: middle; + border-right: solid 1px; + border-left: solid 1px; +} +navigation { + font-weight: bold; + font-family: menlo, monospace; + display: block; + margin: 0 0 20px 0; +} +navigation > a { + margin-right: 10px; +} +.footpara { display: inline; } +.footdef > sup { + font-size: 16px; + vertical-align: middle; +} +.footdef > sup::after { + content: ": "; +} /* colors $base03: #002b36; diff --git a/src/index.org b/src/index.org index 3632e05..e45b1ac 100644 --- a/src/index.org +++ b/src/index.org @@ -1,5 +1,4 @@ #+TITLE: Welcome! -#+DATE: 2019-07-04 #+KEYWORDS: programming #+AUTHOR: Yann Esposito #+EMAIL: yann.esposito@gmail.com @@ -7,6 +6,7 @@ #+LANGUAGE: en #+LANG: en #+OPTIONS: H:5 +#+STARTUP: showeverything This is a new take on my personal blog. I tried to have some minimalism in mind but not too much. @@ -27,7 +27,7 @@ With [[http://orgmode.org][org-mode]] You can have a basic demo about most supported content styles/type (paragraphs, lists, tables, etc...) [[file:./demo.org][here]]. -* Code magic :noexport: +* Code magic :noexport: #+begin_src elisp :results none (require 'org) (require 'ox-publish) @@ -37,8 +37,8 @@ lists, tables, etc...) [[file:./demo.org][here]]. (defun org-blog-prepare (project-plist) "With help from `https://github.com/howardabrams/dot-files'. - Touch `index.org' to rebuilt it. - Argument `PROJECT-PLIST' contains information about the current project." + Touch `index.org' to rebuilt it. + Argument `PROJECT-PLIST' contains information about the current project." (let* ((base-directory (plist-get project-plist :base-directory)) (buffer (find-file-noselect (expand-file-name "index.org" base-directory) t))) (with-current-buffer buffer @@ -52,22 +52,27 @@ lists, tables, etc...) [[file:./demo.org][here]]. "" "")) - (defun org-blog-preamble (info) - "Pre-amble for whole blog." - (concat - "Her.esy.fun" - (when-let ((date (get-from-info info :date))) - (format " - %s" date)) - "")) - (defun menu () "Blog menu" (concat - "" - "Home" - "Posts" + "" + (mapconcat 'identity + '("Home" + "Posts" + "↑ Top ↑") + " | ") "")) + (defun org-blog-preamble (info) + "Pre-amble for whole blog." + (concat + "
    " + "Her.esy.fun" + (when-let ((date (get-from-info info :date))) + (format " - %s" date)) + " - ↓ menu ↓" + "
    ")) + (defun get-from-info (info k) (let ((i (car (plist-get info k)))) (when (and i (stringp i)) @@ -75,26 +80,30 @@ lists, tables, etc...) [[file:./demo.org][here]]. (defun org-blog-postamble (info) "Post-amble for whole blog." - (concat "" - "
    " - (menu))) + (concat + "
    " + "" + (menu) + "
    ")) (defun org-blog-sitemap-format-entry (entry _style project) "Return string for each ENTRY in PROJECT." @@ -194,4 +203,3 @@ lists, tables, etc...) [[file:./demo.org][here]]. 'my-org-export-add-target-blank-to-http-links) #+end_src - diff --git a/src/posts/2019-07-04-org-publish.org b/src/posts/2019-07-04-static-org-publish.org similarity index 80% rename from src/posts/2019-07-04-org-publish.org rename to src/posts/2019-07-04-static-org-publish.org index ad6199c..c1be706 100644 --- a/src/posts/2019-07-04-org-publish.org +++ b/src/posts/2019-07-04-static-org-publish.org @@ -6,15 +6,13 @@ This is the first article using my new blog system. -Each time I try different things. - +Once in a while, I create a new personal website. A long time ago, I used PHP for my first website. I used include and took care of XHTML pages validation. -Then I used [[http://nanoc.ws][nanoc]], a ruby static website. -Then I switched to [[https://jaspervdj.be/hakyll/][hakyll]] because I wanted to switch to a Haskell's written tool. -Now I'll try to use emacs [[http://orgmode.org][org-mode]]. - -So the article is a classical, Why?, How? +Then I used [[http://nanoc.ws][nanoc]], a ruby static website generator. +Then I switched to [[https://jaspervdj.be/hakyll/][hakyll]] because I wanted to switch to a Haskell's written +tool. +Now I'll try to use [[http://orgmode.org][org-mode]]. * Why? @@ -28,8 +26,8 @@ Then I started to work in Clojure and I heard that emacs might certainly be a better fit for LISP dialiects. But, I couldn't switch to an editor without vim keybindings support because they are so great once you're used to them. -But miracle it was about the time [[http://spacemacs.org][spacemacs]] appeared and I switched. -It was really impressive how well the vim keybindings worked so well. +By chance it was about the same time that [[http://spacemacs.org][spacemacs]] appeared and I switched. +Is is really impressive how well the vim keybindings are supported. Even most of the advanced vim features I used to use worked like a charm. The first benefit of emacs is you can configure emacs with elisp. diff --git a/src/posts/draft-professional-lessons-and-opinions.org b/src/posts/draft-professional-lessons-and-opinions.org index cb9b917..db2976a 100644 --- a/src/posts/draft-professional-lessons-and-opinions.org +++ b/src/posts/draft-professional-lessons-and-opinions.org @@ -5,15 +5,56 @@ #+KEYWORDS: programming, blog, org-mode #+DESCRIPTION: Different divagations about my experiences in the professional world of Software Developper -* Technical Choices - + #+begin_comment How to choose a programming language/paradigm to write with. - programming is about making the program do what you want it to do. - not much told, lot harder, and not as natural/intuitive; a program should not do something you do not want it to do. + - programming paradigms, functional is superior because it better fit all real-life scenarios. - in Machine Learning, Kolmogorov complexity. Object Oriented is worse than Functional programming to represent naturally many real life problems. + +What did I learned? Is it a set of specific knowledges or can we discover great +common principles? + +- restart from zero, tabula rasa, what is programming? + #+end_comment + +I could talk to much about that. +But a few short written down lessons. + +If you want to reach productivity and not necessarily enlightenment. +You have to stop learning and use what you know well. +And do not try to use things you don't know. + +In particular, most programming languages/ide/workflow/utils/tools have basic +and advanced features. +If want want to produce and deliver in time. Your best bet is to limit yourselve to +a minimal set of features that give you enough power of combination instead of +looking for a super generic strong solution. + +Clojure for example has: + +- functions +- higher-level functions +- destructuring +- defmethods +- protocols +- macros +- atoms, agents, core.async +- Java FFI + +In fact, writing a fully working app you only need, basic data structure (edn) and functions. + +That's it. + +I was part of a team that created an advanced full featured app using only those. +No magic, just taking care of the state and not writting spaggethi code. + +* How I choose + - Functional programming is superior to imperative and object oriented + languages