Skip to content

Commit ded6862

Browse files
author
Robert Brodie
authored
Merge pull request #420 from swlodarski-sumoheavy/10.1.x-dependencies
Update dependencies
2 parents 1058f86 + 818c082 commit ded6862

4 files changed

Lines changed: 64 additions & 47 deletions

File tree

.github/workflows/release.yml

Lines changed: 24 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -69,15 +69,23 @@ jobs:
6969
VERSION: ${{ steps.version.outputs.version }}
7070
run: |
7171
git add src/BitPaySDK/Env.php phpdoc.dist.xml
72-
git commit -m "Bump version to $VERSION"
73-
git push origin "$BRANCH"
72+
if git diff --cached --quiet; then
73+
echo "No changes to commit - version already bumped"
74+
else
75+
git commit -m "Bump version to $VERSION"
76+
git push origin "$BRANCH"
77+
fi
7478
7579
- name: Create and push tag
7680
env:
7781
VERSION: ${{ steps.version.outputs.version }}
7882
run: |
79-
git tag "$VERSION"
80-
git push origin "$VERSION"
83+
if git rev-parse "$VERSION" >/dev/null 2>&1; then
84+
echo "Tag $VERSION already exists"
85+
else
86+
git tag "$VERSION"
87+
git push origin "$VERSION"
88+
fi
8189
8290
- name: Get merged PR titles and format release notes
8391
id: changelog
@@ -86,13 +94,22 @@ jobs:
8694
OVERVIEW: ${{ inputs.overview }}
8795
BRANCH: ${{ inputs.branch }}
8896
REPOSITORY: ${{ github.repository }}
97+
VERSION: ${{ steps.version.outputs.version }}
8998
run: |
9099
git fetch --tags
91100
92-
# Get most recent and previous tags
101+
# Get all tags sorted by creation date (newest first)
93102
tags=($(git tag --sort=-creatordate))
94-
new_tag="${tags[0]}"
95-
prev_tag="${tags[1]}"
103+
104+
# Find the current version tag and get the previous one
105+
new_tag="$VERSION"
106+
prev_tag=""
107+
for i in "${!tags[@]}"; do
108+
if [[ "${tags[$i]}" == "$VERSION" ]]; then
109+
prev_tag="${tags[$((i+1))]}"
110+
break
111+
fi
112+
done
96113
97114
if [ -z "$prev_tag" ]; then
98115
echo "Warning: No previous tag found. Skipping full changelog link."

composer.lock

Lines changed: 38 additions & 38 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

phpdoc.dist.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
<output>docs</output>
1111
</paths>
1212

13-
<version number="10.1.1">
13+
<version number="10.1.2">
1414
<api format="php">
1515
<source dsn=".">
1616
<path>src</path>

src/BitPaySDK/Env.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ interface Env
1717
public const TEST_URL = "https://test.bitpay.com/";
1818
public const PROD_URL = "https://bitpay.com/";
1919
public const BITPAY_API_VERSION = "2.0.0";
20-
public const BITPAY_PLUGIN_INFO = "BitPay_PHP_Client_v10.1.1";
20+
public const BITPAY_PLUGIN_INFO = "BitPay_PHP_Client_v10.1.2";
2121
public const BITPAY_API_FRAME = "std";
2222
public const BITPAY_API_FRAME_VERSION = "1.0.0";
2323
public const BITPAY_DATETIME_FORMAT = 'Y-m-d\TH:i:s\Z';

0 commit comments

Comments
 (0)