github.com/jaylevin/jenkins-library@v1.230.4/.github/workflows/release-go.yml (about)

     1  name: Create new Release
     2  
     3  on:
     4    repository_dispatch:
     5      types: perform-release
     6    schedule:
     7      - cron: '0 9 * * 1'
     8  
     9  jobs:
    10    build:
    11      name: Publish
    12      runs-on: ubuntu-latest
    13      steps:
    14        - uses: actions/checkout@v1
    15        # Workaround for https://github.com/SAP/jenkins-library/issues/1723, build only works with jdk8 currently
    16        - uses: actions/setup-java@v1
    17          with:
    18            java-version: '8'
    19        - name: Prepare Release
    20          run: |
    21            curl --insecure --silent --location --write-out '%{http_code}' --output ./piper_master https://github.com/SAP/jenkins-library/releases/latest/download/piper_master
    22            curl --insecure --silent --location --write-out '%{http_code}' --output ./piper_master-darwin.x86_64 https://github.com/SAP/jenkins-library/releases/latest/download/piper_master-darwin.x86_64
    23            curl --insecure --silent --location --write-out '%{http_code}' --output ./piper_master-win.x86_64.exe https://github.com/SAP/jenkins-library/releases/latest/download/piper_master-win.x86_64.exe
    24            cp ./piper_master ./piper
    25            cp ./piper_master-darwin.x86_64 ./piper-darwin.x86_64
    26            cp ./piper_master-win.x86_64.exe ./piper-win.x86_64.exe
    27            npm install semver --quiet
    28            echo "PIPER_version=v$(node_modules/.bin/semver -i minor $(curl --silent "https://api.github.com/repos/$GITHUB_REPOSITORY/releases/latest" | jq -r .tag_name))" >> $GITHUB_ENV
    29        - uses: SAP/project-piper-action@master
    30          name: 'publish Linux master binary'
    31          with:
    32            piper-version: master
    33            command: githubPublishRelease
    34            flags: --token ${{ secrets.GITHUB_TOKEN }} --assetPathList ./piper_master --assetPathList ./piper --assetPathList ./piper_master-darwin.x86_64 --assetPathList ./piper-darwin.x86_64 --assetPathList ./piper_master-win.x86_64.exe --assetPathList ./piper-win.x86_64.exe
    35        - name: Build and publish jar for consumption in unit tests
    36          run: mvn package
    37        - uses: SAP/project-piper-action@master
    38          name: 'publish Piper jar'
    39          with:
    40            piper-version: master
    41            command: githubPublishRelease
    42            flags: --token ${{ secrets.GITHUB_TOKEN }} --version latest --assetPath ./target/jenkins-library.jar