Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
80 changes: 80 additions & 0 deletions .github/workflows/changelog.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
# This is a basic workflow to help you get started with Actions

name: CHANGELOG

# Controls when the workflow will run
on:
# Triggers the workflow on push or pull request events but only for the main branch
push:
branches: [ main ]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
build:
# The type of runner that the job will run on
runs-on: ubuntu-latest

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v5
with:
fetch-depth: '0'
- name: Setup PHP
id: setup-php
uses: shivammathur/setup-php@v2
with:
php-version: '7.4'
tools: php-parallel-lint/php-var-dump-check, parallel-lint, cs2pr, phpcs
- uses: actions/setup-node@v3
with:
node-version: 14.x
registry-url: 'https://registry.npmjs.org'
- name: Print PHP version
run: echo ${{ steps.setup-php.outputs.php-version }}
- name: Run PHPCS
run: phpcs -q --report=checkstyle --standard=codesniffer/ruleset.xml --extensions=php --ignore=tx/*,/vendor/* . | cs2pr --graceful-warnings
- name: Run Parallel Lint
run: parallel-lint --exclude vendor/ .
- name: Run VarDump Check
run: var-dump-check --extensions php --tracy --exclude vendor/ .
- name: Run autotranslator
run: |
php ./.tx/autotranslator.php fr_FR it_IT ${{ secrets.GOOGLE_API_TRANSLATE }}
php ./.tx/autotranslator.php fr_FR en_US ${{ secrets.GOOGLE_API_TRANSLATE }}
php ./.tx/autotranslator.php fr_FR es_ES ${{ secrets.GOOGLE_API_TRANSLATE }}
php ./.tx/autotranslator.php fr_FR de_DE ${{ secrets.GOOGLE_API_TRANSLATE }}
php ./.tx/autotranslator.php fr_FR pt_PT ${{ secrets.GOOGLE_API_TRANSLATE }}
php ./.tx/autotranslator.php fr_FR pl_PL ${{ secrets.GOOGLE_API_TRANSLATE }}
- name: Run changelog
run: npx lerna-changelog --from=v0.0.0 > ChangeLog.md
env:
GITHUB_AUTH: ${{ secrets.GITHUB_TOKEN }}
- name: Bump version and push tag
uses: Net-Logic/github-dolibarr-action@main
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
REPO_OWNER: frederic34
RELEASE_BRANCH: main
RELEASE_BRANCHES: main
MODULE: googlerecaptcha
CLASSNAME: Googlerecaptcha
DEFAULT_BUMP: none
INITIAL_VERSION: v0.0.0
- name: Zip Folder
run: |
ls -al
mkdir build/googlerecaptcha
rsync -arv --exclude='.git/' --exclude='.github/' --exclude='.gitignore' --exclude='.tx/' --exclude='build/' --exclude='codesniffer/' --exclude='test/' . ./build/googlerecaptcha
- name: Switch to Release Folder
run: |
cd build
rm module_googlerecaptcha-${{ env.module_version }}.zip 2> /dev/null || true
zip -r module_googlerecaptcha-${{ env.module_version }}.zip googlerecaptcha
- uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: Bump version #none
Loading