build(gha): Add Craft releases as a GitHub action (#538)
This commit is contained in:
		
							
								
								
									
										11
									
								
								.craft.yml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										11
									
								
								.craft.yml
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,11 @@
 | 
				
			|||||||
 | 
					minVersion: "0.10.0"
 | 
				
			||||||
 | 
					github:
 | 
				
			||||||
 | 
					  owner: getsentry
 | 
				
			||||||
 | 
					  repo: onpremise
 | 
				
			||||||
 | 
					changelogPolicy: none
 | 
				
			||||||
 | 
					artifactProvider:
 | 
				
			||||||
 | 
					  name: none
 | 
				
			||||||
 | 
					statusProvider:
 | 
				
			||||||
 | 
					  name: github
 | 
				
			||||||
 | 
					targets:
 | 
				
			||||||
 | 
					  - name: github
 | 
				
			||||||
							
								
								
									
										14
									
								
								.github/workflows/release.yml
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										14
									
								
								.github/workflows/release.yml
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,14 @@
 | 
				
			|||||||
 | 
					on:
 | 
				
			||||||
 | 
					  repository_dispatch:
 | 
				
			||||||
 | 
					    types: [release]
 | 
				
			||||||
 | 
					jobs:
 | 
				
			||||||
 | 
					  release:
 | 
				
			||||||
 | 
					  runs-on: ubuntu-latest
 | 
				
			||||||
 | 
					  name: "Release a new version"
 | 
				
			||||||
 | 
					  steps:
 | 
				
			||||||
 | 
					    - uses: actions/checkout@v2
 | 
				
			||||||
 | 
					    - uses: getsentry/craft-action
 | 
				
			||||||
 | 
					      with:
 | 
				
			||||||
 | 
					        action: prepare
 | 
				
			||||||
 | 
					        version: ${{ github.event.client_payload.version }}
 | 
				
			||||||
 | 
					        dry_run: ${{ github.event.client_payload.dry_run }}
 | 
				
			||||||
							
								
								
									
										11
									
								
								scripts/bump-version.sh
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										11
									
								
								scripts/bump-version.sh
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,11 @@
 | 
				
			|||||||
 | 
					#!/bin/bash
 | 
				
			||||||
 | 
					set -eux
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
 | 
				
			||||||
 | 
					cd $SCRIPT_DIR/..
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					OLD_VERSION="$1"
 | 
				
			||||||
 | 
					NEW_VERSION="$2"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					VERSION=$2
 | 
				
			||||||
 | 
					echo "New version: $VERSION"
 | 
				
			||||||
		Reference in New Issue
	
	Block a user