.. leading zeros are required for `frontmatter` to treat them as dates
rather than strings, apparently per the YAML specification.
This was done by script:
```py
import re
import datetime
import pathlib
import sys
import frontmatter
rx = re.compile(r'^(\s*)date_added:.*$', re.M)
for path_str in sys.argv[1:]:
print(path_str)
path = pathlib.Path(path_str)
post = frontmatter.load(path)
date_added = post.get("date_added", "")
if isinstance(date_added, datetime.date):
continue
if isinstance(date_added, str):
try:
date_added = datetime.datetime.strptime(date_added, "%Y-%m-%d")
except ValueError as exc:
print(f"Failed to parse date {date_added} in {path_str}: {exc}")
continue
date_added = date_added.date()
content = path.read_text("utf-8")
new_content = rx.sub(lambda m: f"{m.group(1)}date_added: {date_added}", content)
assert content != new_content
path.write_text(new_content, "utf-8")
```
48 lines
1.6 KiB
Markdown
48 lines
1.6 KiB
Markdown
---
|
||
layout: download
|
||
board_id: "pine64"
|
||
title: "Pine A64+ Download"
|
||
name: "Pine A64+"
|
||
manufacturer: "Pine64"
|
||
board_url:
|
||
- "https://www.pine64.org/devices/single-board-computers/pine-a64/"
|
||
board_image: "pine64.png"
|
||
download_instructions: ""
|
||
downloads_display: true
|
||
blinka: true
|
||
date_added: 2020-01-09
|
||
features:
|
||
- Wi-Fi
|
||
- Bluetooth/BLE
|
||
- Ethernet
|
||
- HDMI/DisplayPort
|
||
- 40-pin GPIO
|
||
---
|
||
|
||
The PINE A64 (+) is the first pine64.org Single Board Computer powered by Allwinner’s A64 Quad-Core ARM Cortex A53 64-Bit SOC. There are many Operating Systems available for the PINE A64 (+) created by the open source community and various partner projects. Currently the majority of Linux distributions for the PINE A64 are using mainline Linux but there are a number of BSP-based distribution and / or legacy systems that you can download too.
|
||
|
||
Apart from Linux, you also have a choice of a selection of *BSDs, Android, Remix OS and Windows IoT.
|
||
|
||
- Allwinner A64 Quad Core SOC with Mali 400 MP2 GPU
|
||
- DDR3 RAM (up to 2GB)
|
||
- Gigabit Ethernet
|
||
- Micro SD
|
||
- HD Digital Video Out
|
||
- 2x USB 2.0 Host
|
||
- Euler Bus
|
||
- Expansion Bus
|
||
- PI-2 Bus
|
||
- Touch Panel Port (TP)
|
||
- Display Serial Interface (DSI) Port
|
||
- IR R/X Port
|
||
- Real Time Clock Port (RTC)
|
||
- Lithium Battery Port
|
||
- CMOS Sensor Interface Port
|
||
- Optional 802.11GBN + BT 4.0 module expansion module
|
||
- Headphone Jack
|
||
- Micro USB Power (5V 2A) Port
|
||
|
||
## Purchase
|
||
* [pine64 2GB](https://store.pine64.org/?product=pine-a64-board-2gb)
|
||
* [pine64 1GB](https://store.pine64.org/?product=pine-a64-board-1gb)
|
||
* [pine64 512MB](https://store.pine64.org/?product=pine-a64-board)
|