Browse Source

Projects now listed by date. Stuff removed. Added german date formatting. Reordered some pages.

Thomas Buck 3 years ago
parent
commit
a79e155372

+ 8
- 2
input/blog.md View File

@@ -14,10 +14,16 @@ To receive my latest updates, you can subscribe to the [RSS Feed! ![RSS Logo][lo
14 14
 <!--%
15 15
 from datetime import datetime
16 16
 posts = [p for p in pages if "post" in p] # get all blog post pages
17
-posts.sort(key=lambda p: p.get("date"), reverse=True) # sort post pages by date
17
+posts.sort(key=lambda p: p.get("date", "9999-01-01"), reverse=True) # sort post pages by date
18
+lastyear = "0"
18 19
 for p in posts:
20
+    year = p.get("date", "")[0:4]
21
+    if year != lastyear:
22
+        lastyear = year
23
+        print "\n\n#### %s\n" % (year)
24
+
19 25
     date = datetime.strptime(p.date, "%Y-%m-%d").strftime("%B %d, %Y")
20
-    print "  * **[%s](%s)** - %s" % (p.post, p.url, date) # markdown list item
26
+    print "  * **[%s](%s)** - %s" % (p.post, p.url, date)
21 27
 %-->
22 28
 
23 29
  [rss]: rss.xml

+ 2
- 1
input/blog/2015/2015_12_30_caselights.md View File

@@ -1,11 +1,12 @@
1 1
 title: Blog
2 2
 post: CaseLights
3
-date: 2015-12-30
4 3
 comments: true
5 4
 flattr: true
6 5
 github: https://github.com/xythobuz/CaseLights
7 6
 parent: projects
8 7
 position: 60
8
+date: 2015-12-30
9
+update: 2020-06-07
9 10
 ---
10 11
 
11 12
 ### Background

+ 1
- 0
input/blog/2019/2019_06_20_rfid.md View File

@@ -3,6 +3,7 @@ post: Arduino RFID door lock
3 3
 date: 2019-06-20
4 4
 comments: true
5 5
 github: https://git.xythobuz.de/thomas/RFID-Door
6
+parent: projects
6 7
 ---
7 8
 
8 9
 To avoid unwanted access to my old room, I saw the need to install some kind of additional door lock mechanism.

+ 8
- 6
input/index.md View File

@@ -1,6 +1,6 @@
1 1
 title: Home
2 2
 parent: main
3
-position: 10
3
+position: 1
4 4
 flattr: true
5 5
 compat: home
6 6
 noheader: true
@@ -33,17 +33,19 @@ print int(difference_in_years)
33 33
 %--> year old hard- and software developer from Germany.
34 34
 All of my projects are released as free or open-source software on my [GitHub profile](https://github.com/xythobuz) and here on my website. Have fun!
35 35
 
36
-### Recent Blog Posts
36
+### Recent Posts
37 37
 
38 38
 <!--%
39 39
 from datetime import datetime
40
-posts = [p for p in pages if "post" in p] # get all blog post pages
41
-posts.sort(key=lambda p: p.get("date"), reverse=True) # sort post pages by date
40
+posts = [p for p in pages if "date" in p]
41
+posts.sort(key=lambda p: p.get("date"), reverse=True)
42 42
 for p in posts[0:5]:
43 43
     date = datetime.strptime(p.date, "%Y-%m-%d").strftime("%B %d, %Y")
44
-    print "  * **[%s](%s)** - %s" % (p.post, p.url, date) # markdown list item
44
+    if "post" in p:
45
+        print "  * **[%s](%s)** - %s" % (p.post, p.url, date)
46
+    else:
47
+        print "  * **[%s](%s)** - %s" % (p.title, p.url, date)
45 48
 %-->
46
-  * [more...](blog.html)
47 49
 
48 50
 ### Tweets
49 51
 

+ 35
- 10
input/projects.md View File

@@ -1,23 +1,48 @@
1 1
 title: Projects
2 2
 parent: main
3
-position: 30
3
+position: 10
4 4
 ---
5 5
 
6
+This page lists all of my projects that are documented on this website.
7
+Some projects have a specific date and time where I worked on them, so they are listed by date below.
8
+Some others are on-going or still recent for other reasons, these are listed first.
6 9
 
7 10
 <!--%
8
-mpages = [p for p in pages if p.get("parent", "") == "projects" and p.lang == "en"]
9
-mpages.sort(key=lambda p: int(p["position"]))
11
+# prints all pages with parent 'projects' or 'stuff'.
12
+# first the ones without date, sorted by position.
13
+# then afterwards those with date, split by year.
14
+# also supports blog posts with parent.
15
+
16
+enpages = [p for p in pages if p.lang == "en"]
17
+
18
+dpages = [p for p in enpages if p.get("date", "") == ""]
19
+mpages = [p for p in dpages if any(x in p.get("parent", "") for x in [ 'projects', 'stuff' ])]
20
+mpages.sort(key=lambda p: [int(p.get("position", "999"))])
21
+for p in mpages:
22
+    print "  * **[%s](%s)**" % (p.title, p.url)
23
+
24
+dpages = [p for p in enpages if p.get("date", "") != ""]
25
+mpages = [p for p in dpages if any(x in p.get("parent", "") for x in [ 'projects', 'stuff' ])]
26
+mpages.sort(key=lambda p: [p.get("date", "9999-01-01")], reverse = True)
27
+lastyear = "0"
10 28
 for p in mpages:
29
+    title = p.title
11 30
     if p.title == "Blog":
12
-        print "  * **[%s](%s)**" % (p.post, p.url) # markdown list item
13
-    else:
14
-        print "  * **[%s](%s)**" % (p.title, p.url) # markdown list item
31
+        title = p.post
32
+
33
+    year = p.get("date", "")[0:4]
34
+    if year != lastyear:
35
+        lastyear = year
36
+        print "\n\n#### %s\n" % (year)
37
+
38
+    dateto = ""
39
+    if p.get("update", "") != "" and p.get("update", "")[0:4] != year:
40
+        dateto = " (%s - %s)" % (year, p.get("update", "")[0:4])
41
+
42
+    print "  * **[%s](%s)**%s" % (title, p.url, dateto)
15 43
 %-->
16 44
 
17
-### Abandoned Projects
45
+Some other things not explicitly documented on this page are linked below.
18 46
 
19
- * **[avrNetStack](avrnetstack.html)**
20
- * **[xyControl](xycontrol.html)**
21 47
  * **[BaconBar](baconbar)** Reddit Client ([Softpedia Review](http://mac.softpedia.com/get/Internet-Utilities/BaconBar.shtml))
22 48
  * **[OpenRaider](https://github.com/xythobuz/OpenRaider)** Free and Open Source classic Tomb Raider game engine
23
-

input/unlisted/avrnetstack.md → input/projects/avrnetstack.md View File

@@ -1,15 +1,15 @@
1 1
 title: avrNetStack
2 2
 title_de: avrNetStack
3 3
 description: Modular AVR TCP/IP Stack with Ethernet and WiFi support
4
-parent: none
5
-position: 0
4
+parent: projects
5
+position: 50
6 6
 comments: true
7 7
 flattr: true
8 8
 github: https://github.com/xythobuz/avrNetStack
9
+date: 2012-08-10
10
+update: 2014-09-28
9 11
 ---
10 12
 
11
-# {{ page.title }}
12
-
13 13
 [avrNetStack][github] aims to be a very modular Networking Stack running on AVR Microcontrollers and supporting different Network Hardware (ENC28J60, MRF24WB).
14 14
 Select your MCU and hardware driver in the makefile.
15 15
 Compile with "make lib" to create a static library.

+ 1
- 1
input/projects/ledcube.md View File

@@ -1,5 +1,5 @@
1 1
 title: 8x8x8 LED Cube
2
-title_de: 8x8x8 LED Wuerfel
2
+title_de: 8x8x8 LED W&uuml;rfel
3 3
 description: AVR LED Cube with Java Software and Music Visualization
4 4
 parent: projects
5 5
 position: 10

input/unlisted/xycontrol.md → input/projects/xycontrol.md View File

@@ -1,11 +1,13 @@
1 1
 title: xyControl
2 2
 title_de: xyControl
3 3
 description: AVR base Quadrocopter Flight Controller
4
-parent: none
5
-position: 1
4
+parent: projects
5
+position: 40
6 6
 comments: true
7 7
 flattr: true
8 8
 github: https://github.com/xythobuz/xyControl
9
+date: 2012-11-12
10
+update: 2014-09-01
9 11
 ---
10 12
 
11 13
 ![Logo][logo]

+ 0
- 47
input/stuff.md View File

@@ -1,47 +0,0 @@
1
-title: Stuff
2
-parent: main
3
-position: 40
4
----
5
-
6
-<!--%
7
-mpages = [p for p in pages if p.get("parent", "") == "stuff" and p.lang == "en"]
8
-mpages.sort(key=lambda p: int(p["position"]))
9
-for p in mpages:
10
-    if p.title == "Blog":
11
-        print "  * **[%s](%s)**" % (p.post, p.url) # markdown list item
12
-    else:
13
-        print "  * **[%s](%s)**" % (p.title, p.url) # markdown list item
14
-%-->
15
-
16
-### 3D Print Designs ([Repository](https://git.xythobuz.de/thomas/3d-print-designs))
17
-
18
-* [Fabrikator Mini Filament Spool Holder](http://www.thingiverse.com/thing:1427890)
19
-* [Fabrikator Mini Full Graphics Display Holder](http://www.thingiverse.com/thing:1441146)
20
-* [Fabrikator Mini V1.5 Y-Axis Fan Holder](http://www.thingiverse.com/thing:1454399)
21
-* [Fabrikator Mini Logitech C270 Webcam Holder](http://www.thingiverse.com/thing:1531522)
22
-* [Fabrikator Mini Z-Axis Fan Shroud](http://www.thingiverse.com/thing:1531538)
23
-* [Fabrikator Mini V1.5 Z-Axis Wobble Fix](http://www.thingiverse.com/thing:1600007)
24
-* [Sony 600TVL Camera Lens Cap](http://www.thingiverse.com/thing:1443462)
25
-* [Simple Customizable Fan Feet](http://www.thingiverse.com/thing:1465392)
26
-* [Simple Customizable Thumb Screw Rosettes](http://www.thingiverse.com/thing:1531544)
27
-* [Replacement Abus Smoke Detector Holder](http://www.thingiverse.com/thing:1534421)
28
-* [Xiaomi Yi frame for Quanum Trifecta](http://www.thingiverse.com/thing:1563684)
29
-* [Customizable 700TVL FPV camera backplate](http://www.thingiverse.com/thing:1568475)
30
-* [Quanum Trifecta combined GoPro FPV camera holder](http://www.thingiverse.com/thing:1569820)
31
-* [Customizable AVR ESR meter case](http://www.thingiverse.com/thing:1625664)
32
-* [Quanum Trifecta rear landing gear](http://www.thingiverse.com/thing:1642129)
33
-* [Quanum Trifecta FPV top plate](http://www.thingiverse.com/thing:1642135)
34
-* [Customizable long GoPro screw knob](http://www.thingiverse.com/thing:1643650)
35
-* [LiPo Battery Holder](http://www.thingiverse.com/thing:1903936)
36
-* [FPV Watch Mod & Transmitter mount](https://www.thingiverse.com/thing:2003324)
37
-* [Aurora90 battery clips](https://www.thingiverse.com/thing:2086873)
38
-* [Customizable LiPo 2s balance connector saver](https://www.thingiverse.com/thing:2086888)
39
-* [Eachine AIO TX03 case for Aurora100](https://www.thingiverse.com/thing:2369750)
40
-* [Bottle Cap Co2 adapter](https://www.thingiverse.com/thing:2445858)
41
-* [Wilesco Transmission holder for M56](https://www.thingiverse.com/thing:2787459)
42
-* [OrangePi PC Plus case](https://www.thingiverse.com/thing:2787469)
43
-* [OrangePi camera case](https://www.thingiverse.com/thing:2787474)
44
-* [Prusa i3 front camera mount](https://www.thingiverse.com/thing:2787475)
45
-* [Fabrikator Mini Raspberry Pi Zero mount](https://www.thingiverse.com/thing:2796530)
46
-* [Fabrikator Mini Relay Board mount](https://www.thingiverse.com/thing:2796563)
47
-

+ 1
- 0
input/stuff/ssop28.md View File

@@ -6,6 +6,7 @@ position: 80
6 6
 comments: true
7 7
 flattr: true
8 8
 compat: ssop28
9
+date: 2011-07-03
9 10
 ---
10 11
 
11 12
 This is a small PCB to use a SSOP28 SMT IC in a Breadboard or similar with 1" (2,54mm) pin-distance:

+ 7
- 4
page.html View File

@@ -50,8 +50,9 @@
50 50
                 for p in mpages[1:]:
51 51
                     print(entry % (htmlspecialchars(p["url"]), htmlspecialchars(p["title"])))
52 52
             %-->
53
+            <li>-</li>
54
+            <li><a href="https://git.xythobuz.de/explore/repos">Gitea</a></li>
53 55
             <li><a href="https://github.com/xythobuz">GitHub</a></li>
54
-            <li><a href="https://git.xythobuz.de/explore/repos">Git</a></li>
55 56
             <li><a href="printer.html">🔨</a></li>
56 57
             <div class="fonts">
57 58
                 <li><span class="font-big">Text:</span></li>
@@ -82,20 +83,22 @@
82 83
                         print "<h1>%s</h1>" % (page.get("title", ""))
83 84
 
84 85
                 if page.get("date", "") != "":
85
-                    date = datetime.strptime(page["date"], "%Y-%m-%d").strftime("%B %d, %Y")
86 86
                     if page.get("lang", "en") == "de":
87
-                        print "<i>Veroeffentlicht am %s.</i>" % date
87
+                        date = datetime.strptime(page["date"], "%Y-%m-%d").strftime("%d.%m.%Y")
88
+                        print "<i>Ver&ouml;ffentlicht am %s.</i>" % date
88 89
                     else:
90
+                        date = datetime.strptime(page["date"], "%Y-%m-%d").strftime("%B %d, %Y")
89 91
                         print "<i>Published at %s.</i>" % date
90 92
 
91 93
                 if page.get("date", "") != "" and page.get("update", "") != "":
92 94
                     print "<br>"
93 95
 
94 96
                 if page.get("update", "") != "":
95
-                    date = datetime.strptime(page["update"], "%Y-%m-%d").strftime("%B %d, %Y")
96 97
                     if page.get("lang", "en") == "de":
98
+                        date = datetime.strptime(page["update"], "%Y-%m-%d").strftime("%d.%m.%Y")
97 99
                         print "<i>Zuletzt aktualisiert am %s.</i>" % date
98 100
                     else:
101
+                        date = datetime.strptime(page["update"], "%Y-%m-%d").strftime("%B %d, %Y")
99 102
                         print "<i>Last updated at %s.</i>" % date
100 103
         %-->
101 104
         {{ __content__ }}

Loading…
Cancel
Save