3 # Author: Kevin Wentworth
4 # Author: Chris Koeritz
6 # updates just the site avenger core portion of an app.
8 export THISDIR="$( \cd "$(\dirname "$0")" && \pwd )" # obtain the script's working directory.
10 ############################
12 # main body of script.
14 # check for parameters.
15 app_dirname="$1"; shift
17 source "$THISDIR/shared_site_mgr.sh"
21 check_apps_root "$app_dirname"
23 # find proper webroot where the site will be initialized.
24 if [ -z "$app_dirname" ]; then
25 # no dir was passed, so guess it.
26 find_app_folder "$BASE_APPLICATION_PATH"
28 test_app_folder "$BASE_APPLICATION_PATH" "$app_dirname"
30 exit_on_error "finding and testing app folder"
32 # where we expect to find our checkout folder underneath.
33 full_app_dir="$BASE_APPLICATION_PATH/$app_dirname"
35 # simplistic approach here; just go to the folder and pull the changes.
37 pushd "$full_app_dir" &>/dev/null
38 exit_on_error "Changing to app path '$full_app_dir'"
40 dir="$CHECKOUT_DIR_NAME/vendor/siteavenger/avcore"
41 if [ ! -d $dir ]; then
42 echo "The application doesn't seem to use avcore: $full_app_dir"
44 pushd "$dir" &>/dev/null
47 exit_on_error "Pulling git repo for avcore under '$full_app_dir'"
49 echo "Finished updating the avcore portion of site in ${app_dirname}."