i18n
continuous-integration/drone/push Build is failing
Details
continuous-integration/drone/push Build is failing
Details
This commit is contained in:
parent
64448e968f
commit
cc40baf361
|
@ -2,6 +2,7 @@
|
|||
title: Midsomer Murders
|
||||
---
|
||||
|
||||
::: sv
|
||||
**Midsomer Murders – men var är amatörradion?**<br>
|
||||
|
||||
Midsomer Murders är en av de mest älskade brittiska kriminalserierna – inte bara tack vare sina snillrika mordgåtor, utan för hur varje avsnitt placerar oss i en ny, udda och charmig subkultur mitt i den lantliga idyllen. Vi har fått följa historier i allt från new age-mässor, konstnärskollektiv och IQ-sällskap till rugbyklubbar, riddarföreningar och preppers – alltid med värme, humor och ett stänk brittisk excentricitet.
|
||||
|
@ -23,9 +24,9 @@ Jag vill samla in namn och ev. signal för att skicka en vänlig men tydlig väd
|
|||
Låt radioamatörerna få sitt avsnitt!
|
||||
|
||||
Oavsett om du är sändaramatör eller bara älskar serien – skriv gärna under och hjälp oss visa att detta är ett tema som många vill se!
|
||||
:::
|
||||
|
||||
---
|
||||
|
||||
::: en
|
||||
**Midsomer Murders – but where is amateur radio?**<br>
|
||||
|
||||
Midsomer Murders is one of Britain's most beloved detective series – not just for its clever plots, but for the way each episode dives into a new, quirky subculture nestled in the peaceful countryside. We've seen episodes set among new age fairs, art collectives, IQ societies, rugby clubs, medieval reenactors, doomsday preppers – always with warmth, charm, and a distinctly British wink.
|
||||
|
@ -47,6 +48,7 @@ We’re gathering names to kindly but firmly ask the show's writers:
|
|||
Let amateur radio have its episode!
|
||||
|
||||
Whether you're a licensed ham or just a loyal viewer, add your name and help us show there's real interest in this story idea.
|
||||
:::
|
||||
|
||||
---
|
||||
|
||||
|
|
|
@ -6,13 +6,13 @@ title: sa6anw.se
|
|||
<pre><code><div align="center">
|
||||
______ __ __ ______ __ __ ________ _______ ______ __ __ ______
|
||||
/\ ____\ |\_\ /\_\ /\ ____\ |\_\ /\_\ |\ ______\ |\ _____\ |\ ____\ |\_\ |\_\ /\ ____\
|
||||
|\ $$$$$$\ | $$\ / $$ |\ $$$$$$\ | $$ / $$ | $$$$$$$$ | $$$$$$$\ \$$$$$$ | $$\ | $$ |\ $$$$$$\
|
||||
| $$___\$$ | $$$\ / $$$ | $$ | $$ | $$/ $$ | $$__ | $$__/ $$ | $$ | $$$\| $$ | $$ __\$$
|
||||
\$$ ___\ | $$$$\ $$$$ | $$ | $$ | $$ $$ | $$ _\ | $$ _\ $$ | $$ | $$$$\ $$ | $$|\ __\
|
||||
_\$$$$$$\ | $$\$$ $$ $$ | $$ | $$ | $$$$$\ | $$$$$ | $$$$$$$ | $$ | $$\$$ $$ | $$ \$$$$
|
||||
|\_\__| $$ | $$ \$$$| $$ | $$__/\$$ | $$ \$$\ | $$_____ | $$ _| $$_ | $$ \$$$$ | $$__| $$
|
||||
\$$ __\$$ | $$ \$ | $$ \$$ _\ $$ | $$ \$$\ | $$ ____\ | $$ |\_\$$_\ | $$ \$$$ \$$ __\$$
|
||||
\$$$$$$ \$$ \$$ \$$$$$$ \$$ \$$ \$$$$$$$$ \$$ \$$$$$$ \$$ \$$ \$$$$$$
|
||||
|\ ######\ | ##\ / ## |\ ######\ | ## / ## | ######## | #######\ \###### | ##\ | ## |\ ######\
|
||||
| ##___\## | ###\ / ### | ## | ## | ##/ ## | ##__ | ##__/ ## | ## | ###\| ## | ## __\##
|
||||
\## ___\ | ####\ #### | ## | ## | ## ## | ## _\ | ## _\ ## | ## | ####\ ## | ##|\ __\
|
||||
_\######\ | ##\## ## ## | ## | ## | #####\ | ##### | ####### | ## | ##\## ## | ## \####
|
||||
|\_\__| ## | ## \###| ## | ##__/\## | ## \##\ | ##_____ | ## _| ##_ | ## \#### | ##__| ##
|
||||
\## __\## | ## \# | ## \## _\ ## | ## \##\ | ## ____\ | ## |\_\##_\ | ## \### \## __\##
|
||||
\###### \## \## \###### \## \## \######## \## \###### \## \## \######
|
||||
|
||||
SA6ANW 20240105
|
||||
</div></code></pre>
|
||||
|
@ -20,7 +20,7 @@ title: sa6anw.se
|
|||
|
||||
**[smokeping.sa6anw.se](https://smokeping.sa6anw.se)**
|
||||
|
||||
För att köra netnetmaker i ditt egna labb:
|
||||
För att köra smokeping i ditt egna labb:
|
||||
|
||||
- Skapa en `docker-compose.yaml` med följande innehåll
|
||||
|
||||
|
@ -46,5 +46,5 @@ services:
|
|||
```
|
||||
|
||||
- Byt till din domän.
|
||||
- Sen är det bara att köra `docker-compose up -d`
|
||||
- Sen är det bara att köra `docker compose up -d`
|
||||
|
||||
|
|
21
mkdocs.yml
21
mkdocs.yml
|
@ -13,9 +13,9 @@ nav:
|
|||
- Caddy: caddy.md
|
||||
- sa6anw.se: sa6anwse.md
|
||||
- Smokeping: smokeping.md
|
||||
|
||||
theme:
|
||||
name: 'material'
|
||||
|
||||
language: sv
|
||||
font:
|
||||
text: 'Ubuntu'
|
||||
|
@ -36,18 +36,23 @@ theme:
|
|||
toggle:
|
||||
icon: material/weather-night
|
||||
name: Embrace the dark side
|
||||
|
||||
features:
|
||||
- navigation.tabs
|
||||
- navigation.instant
|
||||
- i18n
|
||||
|
||||
plugins:
|
||||
- search
|
||||
- open-in-new-tab
|
||||
# - git-revision-date-localized:
|
||||
# enable_creation_date: true
|
||||
# locale: sv
|
||||
# fallback_to_build_date: true
|
||||
# type: date
|
||||
- i18n:
|
||||
default_language: sv
|
||||
languages:
|
||||
sv: Svenska
|
||||
en: English
|
||||
|
||||
extra_css:
|
||||
- stylesheets/extra.css
|
||||
- overrides/hide-titles.css
|
||||
- overrides/hide-toc.css
|
||||
- overrides/header__title.css
|
||||
|
||||
|
||||
|
|
|
@ -3,4 +3,4 @@ mkdocs-material==9.6.12
|
|||
mkdocs-open-in-new-tab==1.0.3
|
||||
mkdocs-git-revision-date-localized-plugin==1.2.0
|
||||
mkdocs-minify-plugin==0.7.1
|
||||
|
||||
mkdocs-static-i18n
|
||||
|
|
|
@ -0,0 +1,40 @@
|
|||
import os
|
||||
import re
|
||||
|
||||
SOURCE_DIR = "docs"
|
||||
OUTPUT_DIRS = {
|
||||
"sv": "docs_sv",
|
||||
"en": "docs_en"
|
||||
}
|
||||
|
||||
lang_block_re = re.compile(r":::\s*(sv|en)\n(.*?)\n:::", re.DOTALL)
|
||||
|
||||
def split_content_by_language(content):
|
||||
blocks = {"sv": "", "en": ""}
|
||||
pos = 0
|
||||
for match in lang_block_re.finditer(content):
|
||||
start, end = match.span()
|
||||
lang, text = match.groups()
|
||||
neutral = content[pos:start]
|
||||
for l in blocks:
|
||||
blocks[l] += neutral
|
||||
blocks[lang] += text.strip() + "\n\n"
|
||||
pos = end
|
||||
tail = content[pos:]
|
||||
for l in blocks:
|
||||
blocks[l] += tail
|
||||
return blocks
|
||||
|
||||
for filename in os.listdir(SOURCE_DIR):
|
||||
if filename.endswith(".md"):
|
||||
filepath = os.path.join(SOURCE_DIR, filename)
|
||||
with open(filepath, "r", encoding="utf-8") as f:
|
||||
content = f.read()
|
||||
|
||||
blocks = split_content_by_language(content)
|
||||
|
||||
for lang, text in blocks.items():
|
||||
os.makedirs(OUTPUT_DIRS[lang], exist_ok=True)
|
||||
out_path = os.path.join(OUTPUT_DIRS[lang], filename)
|
||||
with open(out_path, "w", encoding="utf-8") as f:
|
||||
f.write(text.strip())
|
Loading…
Reference in New Issue