CI: Fix branch names (#664)
This commit is contained in:
		
							parent
							
								
									54278b9adc
								
							
						
					
					
						commit
						b1bbf1730c
					
				
							
								
								
									
										23
									
								
								.github/workflows/build.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										23
									
								
								.github/workflows/build.yml
									
									
									
									
										vendored
									
									
								
							| @ -48,13 +48,22 @@ jobs: | |||||||
|           test -d artifacts && rm -rf artifacts || true |           test -d artifacts && rm -rf artifacts || true | ||||||
|           mkdir artifacts |           mkdir artifacts | ||||||
|        |        | ||||||
|       - name: 'Generate tag suffix' |       - name: 'Generate suffix and folder name' | ||||||
|         if: startsWith(github.ref, 'refs/tags/') == true |         run: | | ||||||
|         run: echo "SUFFIX=$(git describe --tags --abbrev=0)"  >> $GITHUB_ENV |           REF=${{ github.ref }} | ||||||
|  |           if [[ ${{ github.event_name }} == 'pull_request' ]]; then | ||||||
|  |             REF=${{ github.head_ref }} | ||||||
|  |           fi | ||||||
|  |           REF=${REF##*/} | ||||||
|            |            | ||||||
|       - name: 'Generate branch suffix' |           if [[ "${{ github.ref }}" == "refs/tags/"* ]]; then | ||||||
|         if: startsWith(github.ref, 'refs/tags/') != true |             SUFFIX=${REF} | ||||||
|         run: echo "SUFFIX=$(git rev-parse --abbrev-ref HEAD)-$(date +'%d%m%Y')-$(git rev-parse --short HEAD)" >> $GITHUB_ENV |           else | ||||||
|  |             SUFFIX=${REF}-$(date +'%d%m%Y')-$(echo ${GITHUB_SHA} | cut -c1-8) | ||||||
|  |           fi | ||||||
|  |            | ||||||
|  |           echo "SUFFIX=${SUFFIX}" >> $GITHUB_ENV | ||||||
|  |           echo "ARTIFACTS_PATH=${REF}" >> $GITHUB_ENV | ||||||
| 
 | 
 | ||||||
|       - name: 'Build bootloader in docker' |       - name: 'Build bootloader in docker' | ||||||
|         uses: ./.github/actions/docker |         uses: ./.github/actions/docker | ||||||
| @ -178,7 +187,7 @@ jobs: | |||||||
|         with: |         with: | ||||||
|           switches: -avzP --delete |           switches: -avzP --delete | ||||||
|           path: artifacts/ |           path: artifacts/ | ||||||
|           remote_path: "${{ secrets.RSYNC_DEPLOY_BASE_PATH }}${GITHUB_REF##*/}/" |           remote_path: "${{ secrets.RSYNC_DEPLOY_BASE_PATH }}${ARTIFACTS_PATH}/" | ||||||
|           remote_host: ${{ secrets.RSYNC_DEPLOY_HOST }} |           remote_host: ${{ secrets.RSYNC_DEPLOY_HOST }} | ||||||
|           remote_port: ${{ secrets.RSYNC_DEPLOY_PORT }} |           remote_port: ${{ secrets.RSYNC_DEPLOY_PORT }} | ||||||
|           remote_user: ${{ secrets.RSYNC_DEPLOY_USER }} |           remote_user: ${{ secrets.RSYNC_DEPLOY_USER }} | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Anna Prosvetova
						Anna Prosvetova