|
| 1 | +name: Run experiment 3 |
| 2 | +description: "Runs experiment 3 of the build validation scripts for Gradle" |
| 3 | + |
| 4 | +inputs: |
| 5 | + gitRepo: |
| 6 | + description: "The URL for the Git repository to validate" |
| 7 | + required: true |
| 8 | + gitBranch: |
| 9 | + description: "The branch for the Git repository to validate" |
| 10 | + required: false |
| 11 | + gitCommitId: |
| 12 | + description: "The Git commit id for the Git repository to validate" |
| 13 | + required: false |
| 14 | + projectDir: |
| 15 | + description: "The build invocation directory within the Git repository" |
| 16 | + required: false |
| 17 | + tasks: |
| 18 | + description: "The Gradle tasks to invoke" |
| 19 | + required: false |
| 20 | + args: |
| 21 | + description: "Additional arguments to pass to Gradle" |
| 22 | + required: false |
| 23 | + gradleEnterpriseUrl: |
| 24 | + description: "The URL for the Gradle Enterprise server to connect to" |
| 25 | + required: false |
| 26 | + enableGradleEnterprise: |
| 27 | + description: "Enables Gradle Enterprise on a project not already connected" |
| 28 | + required: false |
| 29 | + |
| 30 | +runs: |
| 31 | + using: "composite" |
| 32 | + steps: |
| 33 | + - name: Run Gradle Experiment 3 |
| 34 | + id: run |
| 35 | + run: | |
| 36 | + cd gradle-enterprise-gradle-build-validation |
| 37 | +
|
| 38 | + EXTRA_ARGS="" |
| 39 | + if [ ! -z "${{ inputs.gitBranch }}" ]; then |
| 40 | + EXTRA_ARGS="$EXTRA_ARGS -b ${{ inputs.gitBranch }}" |
| 41 | + fi |
| 42 | + if [ ! -z "${{ inputs.gitCommitId }}" ]; then |
| 43 | + EXTRA_ARGS="$EXTRA_ARGS -c ${{ inputs.gitCommitId }}" |
| 44 | + fi |
| 45 | + if [ ! -z "${{ inputs.projectDir }}" ]; then |
| 46 | + EXTRA_ARGS="$EXTRA_ARGS -p ${{ inputs.projectDir }}" |
| 47 | + fi |
| 48 | + if [ ! -z "${{ inputs.tasks }}" ]; then |
| 49 | + EXTRA_ARGS="$EXTRA_ARGS -t ${{ inputs.tasks }}" |
| 50 | + fi |
| 51 | + if [ ! -z "${{ inputs.args }}" ]; then |
| 52 | + EXTRA_ARGS="$EXTRA_ARGS -a ${{ inputs.args }}" |
| 53 | + fi |
| 54 | + if [ ! -z "${{ inputs.gradleEnterpriseUrl }}" ]; then |
| 55 | + EXTRA_ARGS="$EXTRA_ARGS -s ${{ inputs.gradleEnterpriseUrl }}" |
| 56 | + fi |
| 57 | + if [ ! -z "${{ inputs.enableGradleEnterprise }}" ]; then |
| 58 | + EXTRA_ARGS="$EXTRA_ARGS -e" |
| 59 | + fi |
| 60 | +
|
| 61 | + # run experiment |
| 62 | + ./03-validate-local-build-caching-different-locations.sh -r ${{ inputs.gitRepo }} $EXTRA_ARGS |
| 63 | + shell: bash |
0 commit comments