32 lines
		
	
	
		
			851 B
		
	
	
	
		
			Groovy
		
	
	
	
	
	
			
		
		
	
	
			32 lines
		
	
	
		
			851 B
		
	
	
	
		
			Groovy
		
	
	
	
	
	
| pipeline {
 | |
|     agent any
 | |
| 
 | |
|     options {
 | |
|         buildDiscarder(logRotator(numToKeepStr: '48', artifactNumToKeepStr: '96'))
 | |
|         timeout(time: 12, unit: 'MINUTES')
 | |
|     }
 | |
|     triggers {
 | |
|         pollSCM('*/10 * * * *')
 | |
|     }
 | |
|     stages {
 | |
|         stage('Build') {
 | |
|             steps {
 | |
|                 echo 'Cleaning...'
 | |
|                 sh './gradlew clean'
 | |
|                 echo 'Building..'
 | |
|                 sh './gradlew build --stacktrace'
 | |
|             }
 | |
|         }
 | |
|         stage('Deploy') {
 | |
|             steps {
 | |
|                 echo 'Deploying....'
 | |
|                 dir('remappedJars') {
 | |
|                     zip zipFile: './UnoptimizedJars.zip', archive: true, glob: '*.jar'
 | |
|                 }
 | |
|                 dir('shrinkedJars') {
 | |
|                     archiveArtifacts artifacts:'*.jar', fingerprint: false
 | |
|                 }
 | |
|             }
 | |
|         }
 | |
|     }
 | |
| } |