Commit 74f5dee 1 parent 042b2db commit 74f5dee Copy full SHA for 74f5dee
File tree 5 files changed +41
-29
lines changed
5 files changed +41
-29
lines changed Original file line number Diff line number Diff line change
1
+ name : Build MeshChat Packages
2
+ on : push
3
+
4
+ jobs :
5
+ calculate-version :
6
+ runs-on : ubuntu-latest
7
+ outputs :
8
+ build_version : ${{ steps.build-version-slug.outputs.build_version }}
9
+ steps :
10
+ - uses : actions/checkout@v4
11
+ with :
12
+ fetch-depth : 0
13
+ - id : build-version-slug
14
+ run : |
15
+ date=$(date +%Y%m%d)
16
+ branch="${GITHUB_REF_NAME}"
17
+ commit=$(git rev-parse --short HEAD)
18
+ version="${date}-${branch}-${commit}"
19
+
20
+ echo "build_version=$version" >> $GITHUB_OUTPUT
21
+
22
+ build-meshchat-package :
23
+ needs : calculate-version
24
+ uses :
25
+ ./.github/workflows/workflow-meshchat-package.yaml
26
+ with :
27
+ build_version : ${{ needs.calculate-version.outputs.build_version }}
28
+ build_dir : package/meshchat-ipkg
29
+
30
+ build-meshchat-api-package :
31
+ needs : calculate-version
32
+ uses :
33
+ ./.github/workflows/workflow-meshchat-api-package.yaml
34
+ with :
35
+ build_version : ${{ needs.calculate-version.outputs.build_version }}
36
+ build_dir : package/meshchat-ipkg
Original file line number Diff line number Diff line change 30
30
build-meshchat-package :
31
31
needs : create-release
32
32
uses :
33
- ./.github/workflows/build -meshchat-package.yaml
33
+ ./.github/workflows/workflow -meshchat-package.yaml
34
34
with :
35
35
ref : release
36
36
build_version : ${{ needs.create-release.outputs.build_version }}
39
39
build-meshchat-api-package :
40
40
needs : create-release
41
41
uses :
42
- ./.github/workflows/build -meshchat-api-package.yaml
42
+ ./.github/workflows/workflow -meshchat-api-package.yaml
43
43
with :
44
44
build_version : ${{ needs.create-release.outputs.build_version }}
45
45
build_dir : package/meshchat-ipkg
Original file line number Diff line number Diff line change 11
11
ref :
12
12
required : false
13
13
type : string
14
- default : $GITHUB_REF_NAME
15
-
14
+ default : ${{ github.ref_name }}
16
15
17
16
jobs :
18
17
create-meshchat-api-package :
29
28
- run : package/update-version.sh ${{ inputs.build_dir }}
30
29
- run : package/ipk-build.sh ${{ inputs.build_dir }}
31
30
- id : detect-package-file
32
- run : echo "file=$(ls -1 meshchat_ *.ipk)" >> $GITHUB_OUTPUT
31
+ run : echo "file=$(ls -1 meshchat-api_ *.ipk)" >> $GITHUB_OUTPUT
33
32
- run : echo "${{ steps.detect-package-file.outputs.file }}"
34
33
- uses : actions/upload-artifact@v4
35
34
with :
Original file line number Diff line number Diff line change 11
11
ref :
12
12
required : false
13
13
type : string
14
- default : $GITHUB_REF_NAME
14
+ default : ${{ github.ref_name }}
15
15
16
16
jobs :
17
17
create-meshchat-package :
Original file line number Diff line number Diff line change 1
- <<< <<< < HEAD
2
1
#! /bin/bash
3
2
4
3
# This script runs from the top of the project directory and
@@ -45,25 +44,3 @@ sed -i "s/^Version:.*/Version: $version/" $IPK_DIR/CONTROL/control
45
44
if [[ -f $IPK_DIR /www/cgi-bin/meshchatconfig.lua ]]; then
46
45
sed -i " s/^app_version.*$/app_version = \" ${version} \" /" $IPK_DIR /www/cgi-bin/meshchatconfig.lua
47
46
fi
48
- ||||||| parent of 36f653c (Added beginnings of package building code)
49
- =======
50
- #! /bin/bash
51
-
52
- # This script runs from the top of the project directory and
53
- # updates the version number in the control file for the package
54
- # being built.
55
-
56
- IPK_DIR=$1
57
-
58
- if [ " $GITHUB_REF_TYPE " == ' tag' ]; then
59
- # ideally should only get version tags
60
- if [ ${GITHUB_REF_NAME} : " v[0-9]" ]; then
61
- version=" ${GITHUB_REF_NAME# v} "
62
- fi
63
- else
64
- # branch gets date code
65
- version=$( date +%Y%m%d)
66
- fi
67
-
68
- sed -i " s/^Version:.*/Version: $version /" $IPK_DIR /CONTROL/control
69
- >>>>>>> 36f653c (Added beginnings of package building code)
You can’t perform that action at this time.
0 commit comments