fix: add CORS headers, make ci builds as preleases
This commit is contained in:
10
.github/workflows/main.yaml
vendored
10
.github/workflows/main.yaml
vendored
@@ -2,7 +2,8 @@ name: Telegram Mini App Shop Builder
|
||||
|
||||
on:
|
||||
push:
|
||||
tags: ['v*']
|
||||
branches:
|
||||
- master
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
@@ -39,10 +40,12 @@ jobs:
|
||||
with:
|
||||
fetch-depth: 0 # to fetch tags
|
||||
|
||||
- name: Extract tag and set filename
|
||||
- name: Extract latest tag and set filename
|
||||
id: meta
|
||||
run: |
|
||||
TAG=${GITHUB_REF#refs/tags/}
|
||||
LAST_TAG=$(git describe --tags --abbrev=0)
|
||||
SHORT_SHA=$(git rev-parse --short=7 HEAD)
|
||||
TAG="${LAST_TAG}+${SHORT_SHA}"
|
||||
echo "tag=$TAG" >> $GITHUB_OUTPUT
|
||||
echo "filename=oc_telegram_shop_${TAG}.ocmod.zip" >> $GITHUB_OUTPUT
|
||||
|
||||
@@ -58,6 +61,7 @@ jobs:
|
||||
- name: Create GitHub Release
|
||||
uses: softprops/action-gh-release@v2
|
||||
with:
|
||||
prerelease: true
|
||||
tag_name: ${{ steps.meta.outputs.tag }}
|
||||
files: ./build/${{ steps.meta.outputs.filename }}
|
||||
generate_release_notes: true
|
||||
|
||||
Reference in New Issue
Block a user