Compare commits
4
Commits
v0.1.2
..
14d2e81d8c
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
14d2e81d8c | ||
|
|
2883b338f4 | ||
|
|
317d92b9d0 | ||
|
|
346ee7b616 |
@@ -27,8 +27,7 @@ jobs:
|
|||||||
cp -rp . /tmp/$MODULE
|
cp -rp . /tmp/$MODULE
|
||||||
rm -rf /tmp/$MODULE/.git \
|
rm -rf /tmp/$MODULE/.git \
|
||||||
/tmp/$MODULE/.gitea \
|
/tmp/$MODULE/.gitea \
|
||||||
/tmp/$MODULE/CLAUDE.md \
|
/tmp/$MODULE/CLAUDE.md
|
||||||
/tmp/$MODULE/release.sh
|
|
||||||
cd /tmp && zip -r ${MODULE}.zip $MODULE/
|
cd /tmp && zip -r ${MODULE}.zip $MODULE/
|
||||||
mkdir -p $GITHUB_WORKSPACE/dist
|
mkdir -p $GITHUB_WORKSPACE/dist
|
||||||
mv /tmp/${MODULE}.zip $GITHUB_WORKSPACE/dist/
|
mv /tmp/${MODULE}.zip $GITHUB_WORKSPACE/dist/
|
||||||
|
|||||||
@@ -8,8 +8,6 @@ on:
|
|||||||
jobs:
|
jobs:
|
||||||
release:
|
release:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
permissions:
|
|
||||||
contents: write
|
|
||||||
container:
|
container:
|
||||||
image: php:8.2-cli-alpine
|
image: php:8.2-cli-alpine
|
||||||
|
|
||||||
@@ -30,8 +28,7 @@ jobs:
|
|||||||
cp -rp . /tmp/$MODULE
|
cp -rp . /tmp/$MODULE
|
||||||
rm -rf /tmp/$MODULE/.git \
|
rm -rf /tmp/$MODULE/.git \
|
||||||
/tmp/$MODULE/.gitea \
|
/tmp/$MODULE/.gitea \
|
||||||
/tmp/$MODULE/CLAUDE.md \
|
/tmp/$MODULE/CLAUDE.md
|
||||||
/tmp/$MODULE/release.sh
|
|
||||||
cd /tmp && zip -r ${MODULE}.zip $MODULE/
|
cd /tmp && zip -r ${MODULE}.zip $MODULE/
|
||||||
mkdir -p $GITHUB_WORKSPACE/dist
|
mkdir -p $GITHUB_WORKSPACE/dist
|
||||||
mv /tmp/${MODULE}.zip $GITHUB_WORKSPACE/dist/
|
mv /tmp/${MODULE}.zip $GITHUB_WORKSPACE/dist/
|
||||||
@@ -41,17 +38,11 @@ jobs:
|
|||||||
TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
TAG: ${{ github.ref_name }}
|
TAG: ${{ github.ref_name }}
|
||||||
run: |
|
run: |
|
||||||
RESPONSE=$(curl -s -X POST \
|
RELEASE_ID=$(curl -sf -X POST \
|
||||||
-H "Authorization: token $TOKEN" \
|
-H "Authorization: token $TOKEN" \
|
||||||
-H "Content-Type: application/json" \
|
-H "Content-Type: application/json" \
|
||||||
"$GITHUB_SERVER_URL/api/v1/repos/$GITHUB_REPOSITORY/releases" \
|
"$GITHUB_SERVER_URL/api/v1/repos/$GITHUB_REPOSITORY/releases" \
|
||||||
-d "{\"tag_name\":\"$TAG\",\"name\":\"$TAG\"}")
|
-d "{\"tag_name\":\"$TAG\",\"name\":\"$TAG\"}" | jq -r '.id')
|
||||||
echo "API response: $RESPONSE"
|
|
||||||
|
|
||||||
RELEASE_ID=$(echo "$RESPONSE" | jq -r '.id')
|
|
||||||
if [ -z "$RELEASE_ID" ] || [ "$RELEASE_ID" = "null" ]; then
|
|
||||||
echo "Failed to create release" && exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
curl -sf -X POST \
|
curl -sf -X POST \
|
||||||
-H "Authorization: token $TOKEN" \
|
-H "Authorization: token $TOKEN" \
|
||||||
|
|||||||
@@ -20,8 +20,6 @@ class AdminSimpleWithdrawalController extends ModuleAdminController
|
|||||||
$this->list_no_link = false;
|
$this->list_no_link = false;
|
||||||
$this->actions = ['view'];
|
$this->actions = ['view'];
|
||||||
|
|
||||||
parent::__construct();
|
|
||||||
|
|
||||||
$this->fields_list = [
|
$this->fields_list = [
|
||||||
'id_withdrawal_request' => [
|
'id_withdrawal_request' => [
|
||||||
'title' => $this->l('ID'),
|
'title' => $this->l('ID'),
|
||||||
@@ -58,6 +56,8 @@ class AdminSimpleWithdrawalController extends ModuleAdminController
|
|||||||
'filter_key' => 'a!status',
|
'filter_key' => 'a!status',
|
||||||
],
|
],
|
||||||
];
|
];
|
||||||
|
|
||||||
|
parent::__construct();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function renderScopeLabel($value, $row)
|
public function renderScopeLabel($value, $row)
|
||||||
|
|||||||
-29
@@ -1,29 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
set -e
|
|
||||||
|
|
||||||
FILE=simple_withdrawalbutton.php
|
|
||||||
|
|
||||||
# Read current version
|
|
||||||
CURRENT=$(grep "version = '" "$FILE" | grep -o "'[0-9]*\.[0-9]*\.[0-9]*'" | tr -d "'")
|
|
||||||
if [ -z "$CURRENT" ]; then
|
|
||||||
echo "Error: could not read version from $FILE" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Increment patch
|
|
||||||
MAJOR=$(echo "$CURRENT" | cut -d. -f1)
|
|
||||||
MINOR=$(echo "$CURRENT" | cut -d. -f2)
|
|
||||||
PATCH=$(echo "$CURRENT" | cut -d. -f3)
|
|
||||||
NEW="$MAJOR.$MINOR.$((PATCH + 1))"
|
|
||||||
|
|
||||||
echo "Version: $CURRENT → $NEW"
|
|
||||||
|
|
||||||
# Write new version into module file
|
|
||||||
sed -i "s/version = '$CURRENT'/version = '$NEW'/" "$FILE"
|
|
||||||
|
|
||||||
# Commit, tag, push — triggers release pipeline on Gitea
|
|
||||||
git add "$FILE"
|
|
||||||
git commit -m "Bump version to $NEW"
|
|
||||||
git tag "v$NEW"
|
|
||||||
git push
|
|
||||||
git push origin "v$NEW"
|
|
||||||
@@ -27,8 +27,8 @@ class Simple_withdrawalbutton extends Module
|
|||||||
{
|
{
|
||||||
$this->name = 'simple_withdrawalbutton';
|
$this->name = 'simple_withdrawalbutton';
|
||||||
$this->tab = 'administration';
|
$this->tab = 'administration';
|
||||||
$this->version = '0.1.2';
|
$this->version = '0.1.0';
|
||||||
$this->author = 'Arne Weiss';
|
$this->author = 'Cyprès / Akiko Sake';
|
||||||
$this->need_instance = 0;
|
$this->need_instance = 0;
|
||||||
$this->bootstrap = true;
|
$this->bootstrap = true;
|
||||||
$this->ps_versions_compliancy = [
|
$this->ps_versions_compliancy = [
|
||||||
|
|||||||
Reference in New Issue
Block a user