mirror of
https://github.com/cedar2025/Xboard.git
synced 2025-01-22 10:38:14 -05:00
feat(ci): add automatic version generation with timestamp and commit hash
This commit is contained in:
parent
d2462bc683
commit
7ca701a079
6
.github/workflows/docker-publish.yml
vendored
6
.github/workflows/docker-publish.yml
vendored
@ -56,6 +56,12 @@ jobs:
|
|||||||
id: get_version
|
id: get_version
|
||||||
run: echo "version=$(git describe --tags --always)" >> $GITHUB_OUTPUT
|
run: echo "version=$(git describe --tags --always)" >> $GITHUB_OUTPUT
|
||||||
|
|
||||||
|
- name: Update version in app.php
|
||||||
|
run: |
|
||||||
|
VERSION=$(date '+%Y%m%d')-$(git rev-parse --short HEAD)
|
||||||
|
sed -i "s/'version' => '.*'/'version' => '$VERSION'/g" config/app.php
|
||||||
|
echo "Updated version to: $VERSION"
|
||||||
|
|
||||||
- name: Build and push
|
- name: Build and push
|
||||||
id: build-and-push
|
id: build-and-push
|
||||||
uses: docker/build-push-action@v5
|
uses: docker/build-push-action@v5
|
||||||
|
@ -187,5 +187,5 @@ return [
|
|||||||
| The only modification by laravel config
|
| The only modification by laravel config
|
||||||
|
|
|
|
||||||
*/
|
*/
|
||||||
'version' => '0.1.1-dev'
|
'version' => '0.0.1'
|
||||||
];
|
];
|
||||||
|
Loading…
Reference in New Issue
Block a user