Run generate-changelog with xplat node

Summary: This way we don't need to depend on Sandcastle configurations. amurawska pointed out that the header in `generate-changelog.js` indicates it must be run with Node 6, but trying to do so actually raises a Syntax error.

Reviewed By: mweststrate

Differential Revision: D23904875

fbshipit-source-id: 264f3b16d64ebfbae6afb0028715f67624166499
This commit is contained in:
Pascal Hartig
2020-09-25 03:52:36 -07:00
committed by Facebook GitHub Bot
parent d77aaf5cad
commit c282184d9f

View File

@@ -7,9 +7,18 @@
set -e
darwin=false
facebook=false
case "$(uname)" in
Darwin*) darwin=true ;;
esac
case "$(hostname -f)" in
*.facebook.com) facebook=true
esac
nodejs="/usr/bin/env node"
if [[ $facebook == true ]]; then
nodejs="$(hg root)/xplat/third-party/node/bin/node"
fi
if ! jq --version > /dev/null; then
if $darwin; then
@@ -84,7 +93,7 @@ echo "Bumping version number for android related files..."
"$SONAR_DIR"/scripts/bump.sh "$VERSION"
# Generate changelog
"$DESKTOP_DIR"/scripts/generate-changelog.js
$nodejs "$DESKTOP_DIR"/scripts/generate-changelog.js
# Create commit
echo "Committing the files..."