-
Notifications
You must be signed in to change notification settings - Fork 3
Upgrade install tools strategy #104
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR simplifies the tool installation strategy by removing manual file operations and version checking logic, delegating these responsibilities to dedicated scripts included in the distribution package.
- Removes complex version checking and marker file management logic
- Replaces manual file movement operations with calls to dedicated scripts
- Simplifies the overall refresh process by using
repair.sh
andinstall-tools.sh
from the distribution
echo "$RELEASE_ID" | sudo tee "$RELEASE_MARKER_FILE" > /dev/null | ||
|
||
echo "Tools installed successfully." | ||
bash spark-sdk-dist/repair.sh |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No error handling for the repair.sh script execution. If this script fails, the installation process will continue silently, potentially leading to an inconsistent state.
bash spark-sdk-dist/repair.sh | |
bash spark-sdk-dist/repair.sh | |
if [ $? -ne 0 ]; then | |
echo "Error: repair.sh script failed. Aborting installation." >&2 | |
exit 1 | |
fi |
Copilot uses AI. Check for mistakes.
.devcontainer/refreshTools.sh
Outdated
|
||
echo "Tools installed successfully." | ||
bash spark-sdk-dist/repair.sh | ||
LATEST_RELEASE="$LATEST_RELEASE" DIST_DIR="$DIST_DIR" WORKSPACE_DIR=$WORKSPACE_DIR bash spark-sdk-dist/install-tools.sh |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No error handling for the install-tools.sh script execution. If this script fails, the user won't receive clear feedback about the failure.
LATEST_RELEASE="$LATEST_RELEASE" DIST_DIR="$DIST_DIR" WORKSPACE_DIR=$WORKSPACE_DIR bash spark-sdk-dist/install-tools.sh | |
LATEST_RELEASE="$LATEST_RELEASE" DIST_DIR="$DIST_DIR" WORKSPACE_DIR=$WORKSPACE_DIR bash spark-sdk-dist/install-tools.sh | |
if [ $? -ne 0 ]; then | |
echo "Error: install-tools.sh script failed to execute successfully." | |
echo "Please check the logs above for more details." | |
rm -rf $TEMP_DIR | |
exit 1 | |
fi |
Copilot uses AI. Check for mistakes.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
No description provided.