.. 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")
```
1.3 KiB
| layout | board_id | title | name | manufacturer | board_url | board_image | date_added | family | bootloader_id | features | ||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| download | makerdiary_nrf52840_m2_devkit | nRF52840 M.2 Developer Kit Download | nRF52840 M.2 Developer Kit | MakerDiary |
|
makerdiary_nrf52840_m2_devkit.jpg | 2020-07-27 | nrf52840 | nrf52840_m2 |
|
nRF52840 M.2 Developer Kit is a versatile IoT prototyping platform, including the nRF52840 M.2 Module and M.2 Dock. You can use the developer kit to prototype your IoT products and then scale to production faster using the nRF52840 M.2 Module combined with your custom PCB hardware.
The nRF52840 M.2 Module is a removable M.2 E-Key form factor module based on the nRF52840 SoC, supporting Bluetooth 5, Bluetooth mesh, Thread, Zigbee, 802.15.4, ANT and 2.4 GHz proprietary stacks.
The M.2 Dock extends the interfaces compared to the nRF52840 M.2 Module through an M.2 E-Key connector. This design also features a fully-integrated DAPLink debugger with Power Profiling, enabling you to program, debug and perform real-time current profiling of your applications without using external tools.