HEALTH - kaktusztea/szilankrpg GitHub Wiki
Az alábbi eszközök felügyelik, biztosítják a dokumentáció jó állapotát.
Obsidian editor Dataview, ami ellenőrzi, hogy vannak -e gazdátlan, nem linkelt oldalak.
https://github.com/kaktusztea/szilankrpg/blob/master/md/views/note_health.md
Jelenleg megtalálja, de filterezni a találatokat. Nyitottam bug ticketet: linkspector #85
Ezt egy Github Workflow Action ellenőrzi minden git push
alkalmával: az md
könyvtár összes ".md" állományát vizsgálja át a Linkspector nevű Github project segítségével. Az anchor linkeket is ellenőrzi.
- Action: https://github.com/kaktusztea/szilankrpg/actions/workflows/linkspector.yml
- Config: https://github.com/kaktusztea/szilankrpg/blob/master/.linkspector.yml
szilankrpg.wiki repót is kéne vizsgálni Linkspectorral. Nyitottam rá issue ticketet.
Probléma összefoglalása:
https://gist.github.com/kaktusztea/04c56ac9d4b98a26115c2a30edb42cda
Libretranslate https://libretranslate.com
https://github.com/kaktusztea/szilankrpg/actions/workflows/spellcheck.yml
- Letöltjük a latest
hu_HU.dic
éshu_HU.aff
fájlokat, ahu_HU.aff
fájl headert kicsit meg kell javítani, hogy rendesUTF-8
kódolású legyen. -
hunspell
telepítése - action
rojopolis/[email protected]
-
spell_checker: hunspell
→ kierőltetni, hogy ne az aspell tool-t használja
.github/workflows/spellcheck.yaml
name: Spell Check
on: [push]
jobs:
hunspell:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Download latest Hungarian Hunspell dictionary, correct encoding in aff file
run: |
mkdir -p dictionaries/hu_HU
curl -L -o dictionaries/hu_HU/hu_HU.dic https://raw.githubusercontent.com/LibreOffice/dictionaries/master/hu_HU/hu_HU.dic
curl -L -o dictionaries/hu_HU/hu_HU.aff https://raw.githubusercontent.com/LibreOffice/dictionaries/master/hu_HU/hu_HU.aff
sed -i '1iSET UTF-8\nFLAG UTF-8' dictionaries/hu_HU/hu_HU.aff
- name: Install Hunspell and Hungarian directionary
run: |
sudo apt-get update
sudo apt-get install -y hunspell hunspell-hu
- name: Running spellcheck with Hunspell
uses: rojopolis/[email protected]
with:
config_path: .github/spellcheck-config.yaml
task_name: Markdown
spell_checker: hunspell
- name: Remove .dic and .aff files
run: |
rm -rf dictionaries/hu_HU
github/spellcheck-config.yaml
matrix:
- name: Markdown
language: hu_HU
spellcheck:
- hunspell
hunspell:
d: dictionaries/hu_HU/hu_HU
dictionary:
encoding: utf-8
words:
- .github/unique_hun_words.txt
pipeline:
- pyspelling.filters.markdown # Markdown formázás eltávolítása
- pyspelling.filters.html
sources:
- 'md/**/*.md'
default_encoding: utf-8
- source venv
- pip install pyspelling
- pyspelling -c .github/spellcheck-config.yaml
curl -L -o dictionaries/hu_HU/hu_HU.dic_8859-2 https://raw.githubusercontent.com/LibreOffice/dictionaries/master/hu_HU/hu_HU.dic
curl -L -o dictionaries/hu_HU/hu_HU.aff_8859-2 https://raw.githubusercontent.com/LibreOffice/dictionaries/master/hu_HU/hu_HU.aff
iconv -f ISO-8859-2 -t UTF-8 dictionaries/hu_HU/hu_HU.aff_8859-2 > dictionaries/hu_HU/hu_HU.aff
iconv -f ISO-8859-2 -t UTF-8 dictionaries/hu_HU/hu_HU.dic_8859-2 > dictionaries/hu_HU/hu_HU.dic
hunspell -d dictionaries/hu_HU/hu_HU -i utf-8
Ez még nem aktív, de ezt a python libraryt érdemes majd használni.
- Hunspell: https://github.com/nytud/hunspellpy
- aff, dic files (nem tudom, kell -e): innen
import hunspellpy.hunspellpy as hunspell
h = hunspell.HunspellPy()
h.spell('működik') # Returns if word spelleed correctly or not?
(((True)))