@@ -35,52 +35,46 @@ jobs:
35
35
- name : Update tags
36
36
run : |
37
37
git fetch --tags --force origin
38
- - name : Store release tag name as environment variable
38
+ - name : Store release tag name as an environment variable
39
39
run : |
40
40
echo "RELEASE_TAG_NAME=${{github.ref_name}}" >> "$GITHUB_ENV"
41
- - name : Prepare Version
41
+ - name : Extract version strings
42
42
# Extract the version string, version with the release-candidate
43
- # number string, and release-candidate number from the git tag name
44
- # (i.e. RELEASE_TAG_NAME). Store extracted values as environment
45
- # variables in GITHUB_ENV for use in subsequent steps.
43
+ # number string, and release-candidate number from the name of
44
+ # the git tag. (i.e. RELEASE_TAG_NAME).
46
45
run : |
47
46
version_with_rc=${RELEASE_TAG_NAME#apache-arrow-}
48
47
version=${version_with_rc%-rc*}
49
- rc =${version_with_rc#${version}-rc}
50
- echo "ARROW_VERSION_WITH_RC=$version_with_rc" >> "$GITHUB_ENV"
51
- echo "ARROW_VERSION=$version" >> $GITHUB_ENV
52
- echo "ARROW_RC=$rc " >> $GITHUB_ENV
48
+ rc_num =${version_with_rc#${version}-rc}
49
+ echo "ARROW_VERSION_WITH_RC=${ version_with_rc} " >> "${ GITHUB_ENV} "
50
+ echo "ARROW_VERSION=${ version} " >> ${ GITHUB_ENV}
51
+ echo "ARROW_RC_NUM=${rc_num} " >> ${ GITHUB_ENV}
53
52
- name : Extract crossbow job id
54
- # Extract the crossbow job ID from the subject associated with the git
55
- # tag message. Store the extracted ID as an environment variable in
56
- # GITHUB_ENV for use in subsequent steps.
53
+ # Extract the crossbow job ID from the subject field of the git tag subject.
57
54
run : |
58
- crossbow_job_id=$(git for-each-ref refs/tags/$RELEASE_TAG_NAME --format='%(contents:subject)')
59
- echo "CROSSBOW_JOB_ID=$crossbow_job_id" >> "$GITHUB_ENV"
55
+ crossbow_job_id=$(git for-each-ref refs/tags/${ RELEASE_TAG_NAME} --format='%(contents:subject)')
56
+ echo "CROSSBOW_JOB_ID=${ crossbow_job_id} " >> "${ GITHUB_ENV} "
60
57
- name : Setup Archery
61
58
run : |
62
59
python3 -m pip install -e dev/archery[crossbow]
63
60
- name : Download artifacts
64
61
# Download the MLTBX file associated with the crossbow job ID.
65
- # Store the path to the downloaded file as an environment variable
66
- # in GITHUB_ENV for use in subsequent steps.
67
62
run : |
68
- archery crossbow download-artifacts -f matlab -t release-artifacts $CROSSBOW_JOB_ID
69
- basefilename =$(find release-artifacts/$ CROSSBOW_JOB_ID -name '*.mltbx' -type f | xargs basename)
70
- mltbx_file=release-artifacts /$CROSSBOW_JOB_ID/$basefilename
71
- echo "ARROW_MLTBX_FILE=$mltbx_file" >> $GITHUB_ENV
63
+ ./dev/release/04-binary-download.sh ${ARROW_VERSION} ${ARROW_RC_NUM} --task-filter matlab
64
+ base_filename =$(find packages/${ CROSSBOW_JOB_ID} -name '*.mltbx' -type f | xargs basename)
65
+ mltbx_file=packages /$CROSSBOW_JOB_ID/${base_filename}
66
+ echo "ARROW_MLTBX_FILE=${ mltbx_file} " >> $GITHUB_ENV
72
67
- name : Cut Pre-Release
73
68
run : |
74
- target_branch=release-$ARROW_VERSION_WITH_RC
75
- title="Apache Arrow $ARROW_VERSION RC$ARROW_RC "
69
+ target_branch=release-${ ARROW_VERSION_WITH_RC}
70
+ title="Apache Arrow ${ ARROW_VERSION} RC${ARROW_RC_NUM} "
76
71
repository=${{github.repository}}
77
- release_notes="Release Candidate: $ARROW_VERSION RC$ARROW_RC "
72
+ release_notes="Release Candidate: ${ ARROW_VERSION} RC${ARROW_RC_NUM} "
78
73
gh release create \
79
- $RELEASE_TAG_NAME \
80
- $ARROW_MLTBX_FILE \
74
+ ${ RELEASE_TAG_NAME} \
75
+ ${ ARROW_MLTBX_FILE} \
81
76
--prerelease \
82
- --target $target_branch \
83
- --notes "$release_notes" \
84
- --title "$title" \
85
- --repo $repository
86
-
77
+ --target ${target_branch} \
78
+ --notes "${release_notes}" \
79
+ --title "${title}" \
80
+ --repo ${repository}
0 commit comments