-
Notifications
You must be signed in to change notification settings - Fork 452
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
Create a script to create a build drop to enable running functional tests on boxes that didn't build the product. #466
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
#!/bin/bash | ||
|
||
. "$(dirname ${BASH_SOURCE[0]})/../InitializeEnvironment.sh" | ||
|
||
CONFIGURATION=$1 | ||
BUILDDROP_ROOT=$2 | ||
if [ -z $BUILDDROP_ROOT ] || [ -z $CONFIGURATION ]; then | ||
echo 'ERROR: Usage: CreateBuildDrop.sh [configuration] [build drop root directory]' | ||
exit 1 | ||
fi | ||
|
||
# Set up some paths | ||
BUILDDROP_BUILDOUTPUT=$BUILDDROP_ROOT/BuildOutput | ||
BUILDDROP_SRC=$BUILDDROP_ROOT/src | ||
BUILDDROP_PROJFS=$BUILDDROP_SRC/ProjFS.Mac | ||
BUILDDROP_KEXT=$BUILDDROP_BUILDOUTPUT/ProjFS.Mac/Native/Build/Products/$CONFIGURATION | ||
|
||
# Set up the build drop directory structure | ||
rm -rf $BUILDDROP_ROOT | ||
mkdir -p $BUILDDROP_BUILDOUTPUT | ||
mkdir -p $BUILDDROP_SRC | ||
mkdir -p $BUILDDROP_PROJFS | ||
mkdir -p $BUILDDROP_KEXT | ||
|
||
# Copy to the build drop, retaining directory structure. | ||
rsync -avm $VFS_OUTPUTDIR/Git $BUILDDROP_BUILDOUTPUT | ||
rsync -avm $VFS_PUBLISHDIR $BUILDDROP_ROOT | ||
rsync -avm $VFS_SCRIPTDIR $BUILDDROP_SRC/Scripts | ||
rsync -avm $VFS_SRCDIR/ProjFS.Mac/Scripts $BUILDDROP_PROJFS | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Should this keep the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It keeps the script folders so that we can keep the logic on how we run functional tests or install/start the kext encoded in the script. |
||
rsync -avm $VFS_OUTPUTDIR/ProjFS.Mac/Native/Build/Products/$CONFIGURATION/PrjFSKext.kext $BUILDDROP_KEXT |
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.
There are cases in the build scripts that use
sudo
. How do we know when we will need to use that vs not?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.
I'm making the assumption in this script that the CI agent will have access to wherever it is asked to publish the drop. Also, this caught my clumsiness a few times where I fat fingered /[something] instead of ~/[something].