Convert CC-CEDICT #7
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Convert CC-CEDICT | |
on: | |
workflow_dispatch: | |
schedule: | |
# Runs at 00:00 UTC on the 1st day of every month | |
- cron: '0 0 1 * *' | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: '3.10' | |
- name: Download latest CC-CEDICT file | |
run: wget https://www.mdbg.net/chinese/export/cedict/cedict_1_0_ts_utf-8_mdbg.txt.gz | |
- name: Unpack CC-CEDICT file | |
run: gunzip cedict_1_0_ts_utf-8_mdbg.txt.gz | |
- name: Create output directory | |
run: mkdir release | |
- name: Convert CC-CEDICT into Yomitan format | |
id: conversion1 | |
run: python main.py cedict_1_0_ts_utf-8_mdbg.txt --output-directory release/ | |
- name: Convert CC-CEDICT into Yomitan format (Bullets) | |
run: python main.py cedict_1_0_ts_utf-8_mdbg.txt --output-directory release/ --separate | |
- name: Convert CC-CEDICT into Yomitan format (Numbered Pinyin) | |
run: python main.py cedict_1_0_ts_utf-8_mdbg.txt --output-directory release/ --pinyin-numbers | |
- name: Convert CC-CEDICT into Yomitan format (Bullets + Numbered Pinyin) | |
run: python main.py cedict_1_0_ts_utf-8_mdbg.txt --output-directory release/ --separate --pinyin-numbers | |
- name: Create GitHub relase | |
uses: ncipollo/release-action@v1 | |
with: | |
artifacts: "release/*.zip" | |
name: "${{ steps.conversion1.outputs.result }}" | |
commit: "main" | |
tag: "release" | |