build: cicd fixes
This commit is contained in:
12
.github/workflows/main.yaml
vendored
12
.github/workflows/main.yaml
vendored
@@ -2,19 +2,24 @@ name: Telegram Mini App Shop Builder
|
|||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
tags: ['v*']
|
||||||
- master
|
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: write
|
contents: write
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
module-build:
|
module-build:
|
||||||
if: github.ref == 'refs/heads/master'
|
|
||||||
name: Build module.
|
name: Build module.
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Setup PHP 7.4
|
||||||
|
uses: shivammathur/setup-php@v2
|
||||||
|
with:
|
||||||
|
php-version: '7.4'
|
||||||
|
tools: composer
|
||||||
|
|
||||||
- name: Build module
|
- name: Build module
|
||||||
run: |
|
run: |
|
||||||
bash scripts/ci/build.sh "${GITHUB_WORKSPACE}"
|
bash scripts/ci/build.sh "${GITHUB_WORKSPACE}"
|
||||||
@@ -27,7 +32,6 @@ jobs:
|
|||||||
retention-days: 1
|
retention-days: 1
|
||||||
|
|
||||||
release:
|
release:
|
||||||
if: github.ref == 'refs/heads/master'
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: [module-build]
|
needs: [module-build]
|
||||||
steps:
|
steps:
|
||||||
|
|||||||
@@ -9,9 +9,12 @@ echo "Current dir: ${CURRENT_DIR}"
|
|||||||
composer --version
|
composer --version
|
||||||
node -v
|
node -v
|
||||||
npm -v
|
npm -v
|
||||||
|
php -v
|
||||||
|
|
||||||
SRC_PATH="$1"
|
SRC_PATH="$1"
|
||||||
BUILD_PATH="${CURRENT_DIR}/build"
|
BUILD_PATH="${GITHUB_WORKSPACE}/build"
|
||||||
|
|
||||||
|
mkdir -p "$BUILD_PATH"
|
||||||
|
|
||||||
echo "🔨 Starting build process..."
|
echo "🔨 Starting build process..."
|
||||||
echo "ℹ️ Source path: ${SRC_PATH}"
|
echo "ℹ️ Source path: ${SRC_PATH}"
|
||||||
|
|||||||
Reference in New Issue
Block a user