Skip to content

Commit e73d8e4

Browse files
committed
Rearrange to allow binaries been kept
1 parent fa891b0 commit e73d8e4

3 files changed

Lines changed: 37 additions & 43 deletions

File tree

templates/t-extend-database-build.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,20 @@ stages:
4949
pool:
5050
vmImage: ubuntu-latest
5151
jobs:
52+
- template: t-extend-download-binaries.yml
53+
parameters:
54+
packages:
55+
- name: sqlcl
56+
download_location: "$(Build.BinariesDirectory)/sqlcl-latest.zip"
57+
unpack_location: "$(Build.BinariesDirectory)"
58+
url: "https://download.oracle.com/otn_software/java/sqldeveloper/sqlcl-latest.zip"
59+
archive: "zip"
60+
61+
- name: utlplsqlcli
62+
download_location: "$(Build.BinariesDirectory)/utPLSQL-cli.zip"
63+
unpack_location: "$(Build.BinariesDirectory)"
64+
url: "https://github.com/utPLSQL/utPLSQL-cli/releases/download/$(UTPLSQL_CLI_VERSION)/utPLSQL-cli.zip"
65+
archive: "zip"
5266
- job: CreateDatabase
5367
displayName: Create Database
5468
steps:

templates/t-extend-download-binaries.yml

Lines changed: 21 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -19,32 +19,27 @@ parameters:
1919
type: boolean
2020
default: true
2121

22-
stages:
23-
- ${{ if parameters.enableDownload }}:
24-
- stage: DownloadBinaries
25-
pool:
26-
vmImage: ubuntu-latest
27-
jobs:
28-
- job: DownloadBinaries
29-
displayName: Download Build Binaries
30-
steps:
31-
- checkout: none
32-
- ${{ each package in parameters.packages }}:
33-
- bash: |
34-
curl -Lk -o ${{package.download_location}} \
35-
${{package.url}}
36-
displayName: 'Download ${{package.name}}'
3722

38-
- ${{ if eq(package.archive,'zip') }}:
39-
- bash: |
40-
echo Unzipping to ${{package.unpack_location}}
41-
unzip -qq -d ${{package.unpack_location}} ${{package.download_location}}
42-
chmod -R u+x ${{package.unpack_location}}
43-
displayName: 'Unzip ${{package.name}}'
23+
jobs:
24+
- job: DownloadBinaries
25+
displayName: Download Build Binaries
26+
steps:
27+
- checkout: none
28+
- ${{ each package in parameters.packages }}:
29+
- bash: |
30+
curl -Lk -o ${{package.download_location}} \
31+
${{package.url}}
32+
displayName: 'Download ${{package.name}}'
33+
- ${{ if eq(package.archive,'zip') }}:
34+
- bash: |
35+
echo Unzipping to ${{package.unpack_location}}
36+
unzip -qq -d ${{package.unpack_location}} ${{package.download_location}}
37+
chmod -R u+x ${{package.unpack_location}}
38+
displayName: 'Unzip ${{package.name}}'
4439
45-
- ${{ if coalesce(package.clean,true) }}:
46-
- bash: |
47-
rm -rf ${{package.download_location}}
40+
- ${{ if coalesce(package.clean,true) }}:
41+
- bash: |
42+
rm -rf ${{package.download_location}}
4843
49-
ls -ltr $(Build.BinariesDirectory)
50-
displayName: 'Clean ${{package.name}}'
44+
ls -ltr $(Build.BinariesDirectory)
45+
displayName: 'Clean ${{package.name}}'

utlplsql-demo-project.yml

Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -12,23 +12,8 @@ variables:
1212
UTPLSQL_VERSION: 'v3.1.11'
1313
DOCKHER_HUB_REPO: 'utplsqlv3/oracledb'
1414

15-
stages:
16-
- template: templates/t-extend-download-binaries.yml
17-
parameters:
18-
packages:
19-
- name: sqlcl
20-
download_location: "$(Build.BinariesDirectory)/sqlcl-latest.zip"
21-
unpack_location: "$(Build.BinariesDirectory)"
22-
url: "https://download.oracle.com/otn_software/java/sqldeveloper/sqlcl-latest.zip"
23-
archive: "zip"
24-
25-
- name: utlplsqlcli
26-
download_location: "$(Build.BinariesDirectory)/utPLSQL-cli.zip"
27-
unpack_location: "$(Build.BinariesDirectory)"
28-
url: "https://github.com/utPLSQL/utPLSQL-cli/releases/download/$(UTPLSQL_CLI_VERSION)/utPLSQL-cli.zip"
29-
archive: "zip"
30-
31-
- template: templates/t-extend-database-build.yml
15+
extends:
16+
template: templates/t-extend-database-build.yml
3217
parameters:
3318
utplsqlVersion: ${UTPLSQL_VERSION}
3419
utplsqlDir: ${UTPLSQL_DIR}

0 commit comments

Comments
 (0)