Merge pull request #58 from PomeloOfficial/master #14
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: Build mo files | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Install gettext | |
run: sudo apt install gettext | |
- name: Build | |
run: | | |
for i in `find . -name '*.po'`; do echo `basename $i` && msgfmt -o `basename $i .po`.mo `basename $i`; done; | |
mkdir langs | |
cp *.mo langs/ | |
cd langs && zip -q -r langs.zip * && mv langs.zip ../ && cd - | |
- name: Upload langs package | |
uses: WebFreak001/[email protected] | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
upload_url: https://uploads.github.com/repos/typecho/languages/releases/58851283/assets{?name,label} | |
release_id: 58851283 | |
asset_path: ./langs.zip | |
asset_name: langs.zip | |
asset_content_type: application/zip | |
max_releases: 1 |