@@ -5,26 +5,31 @@ version: 0.2
55
66env :
77  variables :
8-     BRANCH : " mainline-1.x " 
8+     BRANCH : " master " 
99  git-credential-helper : yes 
1010  secrets-manager :
11-     GH_TOKEN : Github/aws-crypto-tools-ci-bot:personal\ access\ token  
11+     GH_TOKEN : Github/aws-crypto-tools-ci-bot:ESDK Release Token  
1212
1313phases :
1414  pre_build :
1515    commands :
16-       - git checkout $BRANCH 
1716        #  get new project version
1817      - export VERSION=$(grep version pom.xml | head -n 1 | sed -n 's/[ \t]*<version>\(.*\)<\/version>/\1/p') 
18+       - git config --global user.name "aws-crypto-tools-ci-bot" 
19+       - git config --global user.email "no-reply@noemail.local" 
20+       - echo $GH_TOKEN > token.txt 
21+       - export GH_TOKEN= 
1922        #  install gh cli in order to upload artifacts
2023      - curl -fsSL https://cli.github.com/packages/githubcli-archive-keyring.gpg | gpg --dearmor -o /usr/share/keyrings/githubcli-archive-keyring.gpg 
2124      - echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | tee /etc/apt/sources.list.d/github-cli.list > /dev/null 
2225      - apt update 
2326      - apt install gh 
27+       - git checkout $BRANCH 
2428  build :
2529    commands :
2630      - gh version 
27-       - gh auth login --with-token < $GH_TOKEN 
31+       - gh auth login --with-token < token.txt 
32+       - gh auth status 
2833      - | 
2934        mvn org.apache.maven.plugins:maven-dependency-plugin:3.1.2:get \ 
3035          -DrepoUrl=https://aws.oss.sonatype.org \ 
@@ -37,4 +42,4 @@ phases:
3742        mvn org.apache.maven.plugins:maven-dependency-plugin:3.1.2:get \ 
3843          -DrepoUrl=https://aws.oss.sonatype.org \ 
3944          -Dartifact=com.amazonaws:aws-encryption-sdk-java:${VERSION}:jar:javadoc 
40-        - gh release upload  v${VERSION} ~/.m2/repository/com/amazonaws/aws-encryption-sdk-java/${VERSION}/*.jar 
45+        - gh release create  v${VERSION} ~/.m2/repository/com/amazonaws/aws-encryption-sdk-java/${VERSION}/*.jar -d -F CHANGELOG.md -t "AWS Encryption SDK ${VERSION} Release -- $(date +%Y-%m-%d)"  
0 commit comments