@@ -40,32 +40,35 @@ jobs:
4040 # env:
4141 # GITHUB_TOKEN: ${{ github.token }}
4242
43+ - uses : actions/checkout@v2
44+ with :
45+ fetch-depth : 0
46+ submodules : true
47+ # - name: Initialization environment
48+ # env:
49+ # DEBIAN_FRONTEND: noninteractive
50+ # run: |
51+ # sudo timedatectl set-timezone "$TZ"
52+ # sudo mkdir -p /workdir
53+ # sudo chown $USER:$GROUPS /workdir
4354
44- - name : Initialization environment
45- env :
46- DEBIAN_FRONTEND : noninteractive
47- run : |
48- sudo timedatectl set-timezone "$TZ"
49- sudo mkdir -p /workdir
50- sudo chown $USER:$GROUPS /workdir
5155
5256
5357
5458
55-
56- - name : Clone source code
57- working-directory : /workdir
58- run : |
59- df -hT $PWD
60- git clone $REPO_URL -b $REPO_BRANCH --recursive casa
61- ln -sf /workdir/casa $GITHUB_WORKSPACE/casa
62- ls
59+ # - name: Clone source code
60+ # working-directory: /workdir
61+ # run: |
62+ # df -hT $PWD
63+ # git clone $REPO_URL -b $REPO_BRANCH --recursive casa
64+ # ln -sf /workdir/casa $GITHUB_WORKSPACE/casa
65+ # ls
6366
6467
6568 - name : Set enviroment for github-release
6669 run : |
67- echo "VERSION=$(cat /workdir/casa/ types/system.go | grep CURRENTVERSION | awk '$2 == "CURRENTVERSION"{print $4}' | sed 's/"//g')" >>$GITHUB_ENV
68- echo "BODY=$(cat /workdir/casa/ types/system.go | grep BODY | awk -F= '{print $2}' | sed 's/"//g')" >>$GITHUB_ENV
70+ echo "VERSION=$(cat types/system.go | grep CURRENTVERSION | awk '$2 == "CURRENTVERSION"{print $4}' | sed 's/"//g')" >>$GITHUB_ENV
71+ echo "BODY=$(cat types/system.go | grep BODY | awk -F= '{print $2}' | sed 's/"//g')" >>$GITHUB_ENV
6972
7073
7174
@@ -74,63 +77,61 @@ jobs:
7477 with :
7578 node-version : ' 14'
7679
77- # - name: Build frontend with nodejs and yarn
78- # run: |
79- # cd casa/UI
80- # ls
81- # yarn install
82- # yarn build
80+ # - name: Build frontend with nodejs and yarn
81+ # run: |
82+ # cd casa/UI
83+ # ls
84+ # yarn install
85+ # yarn build
8386
8487 - name : list work
8588 run : pwd
8689
87- # - name: Build with xgo
88- # uses: crazy-max/ghaction-xgo@v1
89- # with:
90- # working_dir: /workdir/casa
91- # xgo_version: latest
92- # go_version: ${{ matrix.go_version }}
93- # dest: build
94- # prefix: casa
95- # targets: linux/amd64,linux/arm64
96- # v: true
97- # x: false
98- # race: false
99- # ldflags: -s -w
100- # buildmode: default
90+ # - name: Build with xgo
91+ # uses: crazy-max/ghaction-xgo@v1
92+ # with:
93+ # xgo_version: latest
94+ # go_version: ${{ matrix.go_version }}
95+ # dest: build
96+ # prefix: casa
97+ # targets: linux/amd64,linux/arm64
98+ # v: true
99+ # x: false
100+ # race: false
101+ # ldflags: -s -w
102+ # buildmode: default
101103
102104 - name : List Files
103105 run : |
104106 ls
105- mkdir -p casa/ build
106- cd casa/ build
107+ mkdir build
108+ cd build
107109 touch casa-linux-amd64
108110 touch casa-linux-arm64
109111 ls
110112 echo "::set-output name=status::success"
111113
112114 - name : Pack builds
113115 run : |
114- cd /workdir
115116 wget $PACK_SH_URL
116117 chmod +x $PACK_SH
117- ./$PACK_SH $(pwd)
118+ ./$PACK_SH
118119 echo "::set-output name=status::success"
119120 - name : list work
120121 run : ls
121122
122- # - name: move
123- # run: |
124- # ls
125- # mv /workdir/casa/upload/linux-amd64-casaos.tar.gz ./linux-amd64-casaos.tar.gz
126- # mv /workdir/casa/upload/linux-arm64-casaos.tar.gz ./linux-arm64-casaos.tar.gz
123+ # - name: move
124+ # run: |
125+ # ls
126+ # mv /workdir/casa/upload/linux-amd64-casaos.tar.gz ./linux-amd64-casaos.tar.gz
127+ # mv /workdir/casa/upload/linux-arm64-casaos.tar.gz ./linux-arm64-casaos.tar.gz
127128 - name : Update release
128129129130 with :
130131 token : ${{ secrets.GITHUB_TOKEN }}
131132 files : >
132- casa/ linux-amd64-casaos.tar.gz
133- casa/ linux-arm64-casaos.tar.gz
133+ linux-amd64-casaos.tar.gz
134+ linux-arm64-casaos.tar.gz
134135 tag : v${{ env.VERSION }}
135136 body : >
136137 ${{ env.BODY }}
0 commit comments