Skip to content

Commit c0963c5

Browse files
committed
Use grep instead of xpath to parse current Swift version
1 parent b8893c8 commit c0963c5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -150,11 +150,11 @@ runs:
150150
151151
#yq -oy '.feed.entry[].title' ${{ runner.temp }}/swift-releases.xml | sort -rn > ${SWIFT_VERSIONS_FILE}
152152
#xmllint --xpath "/*[local-name()='feed']/*[local-name()='entry']/*[local-name()='title']/text()" ${{ runner.temp }}/swift-releases.xml | sort -rn > ${SWIFT_VERSIONS_FILE}
153-
xpath -q -e '/feed/entry/title/text()' ${{ runner.temp }}/swift-releases.xml | sort -rn > ${SWIFT_VERSIONS_FILE}
153+
#xpath -q -e '/feed/entry/title/text()' ${{ runner.temp }}/swift-releases.xml | sort -rn > ${SWIFT_VERSIONS_FILE}
154154
155155
# yq or xmllint are best for this, but they aren't installed by
156156
# default on GH Linux runners, we we just use grep
157-
#grep '<title>' swift-releases.xml | cut -f 2 -d '>' | cut -f 1 -d '<' | grep '^[0-9]' ${{ runner.temp }}/swift-releases.xml | sort -rn > ${SWIFT_VERSIONS_FILE}
157+
grep '<title>' swift-releases.xml | cut -f 2 -d '>' | cut -f 1 -d '<' | grep '^[0-9]' ${{ runner.temp }}/swift-releases.xml | sort -rn > ${SWIFT_VERSIONS_FILE}
158158
159159
# if we hardcode the latest builds, we would need to update them every time a new snapshot is released
160160

0 commit comments

Comments
 (0)