Skip to content

Build and Release Dictionaries #3

Build and Release Dictionaries

Build and Release Dictionaries #3

name: Build and Release Dictionaries
on:
schedule:
- cron: '0 5 * * *' # Runs at 5am UTC after the JMdict files are updated
workflow_dispatch: # Allows manually triggering the workflow
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install atool # atool is needed to extract the rikaitan-import binaries
uses: awalsh128/cache-apt-pkgs-action@latest
with:
packages: atool
version: 1.0
- name: Get Current Date
id: date
run: echo "::set-output name=date::$(date +'%Y-%m-%d')"
- name: Run Build Dicts Script
run: |
bash build_dicts.sh
- name: Create Release
uses: softprops/action-gh-release@v1
with:
files: dst/*
tag_name: ${{ steps.date.outputs.date }}
name: ${{ steps.date.outputs.date }}
token: ${{ secrets.GITHUB_TOKEN }}
body: |
This is an automated release of the dictionaries for ${{ steps.date.outputs.date }}.
For information on how to use these dictionaries, please see the [README](https://github.com/Ajatt-Tools/jmdict-rikaitan).