Release #13
This file contains hidden or 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
# Simple workflow for deploying static content to GitHub Pages | |
name: Release | |
on: | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
inputs: | |
version_tag: | |
description: '請輸入語意化版本標籤 (例如: v1.0.0)' # Input for semantic version tag | |
required: true | |
type: string | |
defaults: | |
run: | |
shell: bash | |
jobs: | |
release: | |
environment: Action Env | |
permissions: | |
contents: write | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: "3.11" | |
- name: Install | |
run: | | |
pip3 install -r requirements.txt | |
- name: Set current date as env variable | |
run: echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV | |
- name: Build | |
run: python main.py release --locationiq-api-key "${{ secrets.LOCATIONIQ_API_KEY }}" --country-code "JP" "KR" "TH" | |
- name: Create Release | |
uses: ncipollo/release-action@v1 | |
with: | |
name: ${{ github.event.inputs.version_tag }} # Use the input tag for the release name | |
artifacts: "output/release.*" | |
draft: false | |
generateReleaseNotes: false # Keep false unless you want auto-generated notes | |
commit: main # Or specify the commit SHA/branch if needed | |
tag: ${{ github.event.inputs.version_tag }} # Use the input tag | |
makeLatest: true # Mark this as the latest stable release | |
- uses: stefanzweifel/git-auto-commit-action@v5 | |
with: | |
commit_message: Auto update reverse geocoding data on ${{ env.TODAY }} | |
file_pattern: meta_data/* |