Changeset 482 for trunk/ICeCoffEE


Ignore:
Timestamp:
07/14/08 03:11:27 (16 years ago)
Author:
Nicholas Riley
Message:

package-ICeCoffEE.sh: Long-overdue use of -e instead of repeated &&.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ICeCoffEE/package-ICeCoffEE.sh

    r385 r482  
    1 #!/bin/sh
     1#!/bin/sh -e
    22
    33set -x -v
     
    66PRODUCT="ICeCoffEE"
    77
    8 cd "$PRODUCT" && \
    9 source VERSION.xcconfig && \
    10 find . -name \*~ -exec rm '{}' \; && \
    11 VERSION=${CURRENT_MARKETING_VERSION} && \
    12 DMG="$PRODUCT-$VERSION.dmg" VOL="$PRODUCT $VERSION" && \
    13 DSTROOT="$PACKAGEDIR/$VOL" && \
    14 sudo rm -rf "$DSTROOT" && \
    15 sudo rm -rf build/ && \
    16 rm -rf build/ && \
    17 xcodebuild -target "ICeCoffEE Installer" -configuration Deployment "DSTROOT=$DSTROOT" DEPLOYMENT_LOCATION=YES install && \
    18 mkdir "$DSTROOT" && \
    19 mv "build/Deployment/$PRODUCT Installer.app" "$DSTROOT/$PRODUCT $VERSION Installer.app" && \
    20 sudo rm -rf build/ && \
    21 find "$DSTROOT" -name ".svn" -type d -exec sudo /bin/rm -rf "{}" \;
     8cd "$PRODUCT"
     9source VERSION.xcconfig
     10find . -name \*~ -exec rm '{}' \;
     11VERSION=${CURRENT_MARKETING_VERSION}
     12DMG="$PRODUCT-$VERSION.dmg" VOL="$PRODUCT $VERSION"
     13DSTROOT="$PACKAGEDIR/$VOL"
     14sudo rm -rf "$DSTROOT"
     15sudo rm -rf build/
     16rm -rf build/
     17xcodebuild -target "ICeCoffEE Installer" -configuration Deployment "DSTROOT=$DSTROOT" DEPLOYMENT_LOCATION=YES install
     18mkdir "$DSTROOT"
     19mv "build/Deployment/$PRODUCT Installer.app" "$DSTROOT/$PRODUCT $VERSION Installer.app"
     20sudo rm -rf build/
     21find "$DSTROOT" -name ".svn" -type d -exec sudo /bin/rm -rf "{}" \; || true
    2222# uncomment to include localizations
    23 find "$DSTROOT" -name \*.lproj -type d -and -not -name English.lproj -exec sudo rm -rf "{}" \;
    24 cd "$PACKAGEDIR" && \
    25 rm -f "$DMG" && \
    26 hdiutil create "$DMG" -megabytes 5 -ov -layout NONE -fs 'HFS+' -volname "$VOL" && \
    27 MOUNT=`hdiutil attach "$DMG"` && \
    28 DISK=`echo "$MOUNT" | sed -ne ' s|^/dev/\([^ ]*\).*$|\1|p'` && \
    29 MOUNTPOINT=`echo "$MOUNT" | sed -ne 's|^.*\(/Volumes/.*\)$|\1|p'` && \
    30 ditto -rsrc "$DSTROOT" "$MOUNTPOINT" && \
    31 sudo chmod -R a+rX,u+w "$MOUNTPOINT" && \
    32 # openUp "$MOUNTPOINT" && \
    33 hdiutil detach $DISK && \
    34 hdiutil resize -sectors min "$DMG" && \
    35 hdiutil convert "$DMG" -format UDZO -imagekey zlib-level=9 -o "z$DMG" && \
    36 mv "z$DMG" "$DMG" && \
    37 hdiutil internet-enable "$DMG" && \
     23find "$DSTROOT" -name \*.lproj -type d -and -not -name English.lproj -exec sudo rm -rf "{}" \; || true
     24cd "$PACKAGEDIR"
     25rm -f "$DMG"
     26# XXX can make shorter now with hdiutil create -srcfolder...
     27hdiutil create "$DMG" -megabytes 5 -ov -layout NONE -fs 'HFS+' -volname "$VOL"
     28MOUNT=`hdiutil attach "$DMG"`
     29DISK=`echo "$MOUNT" | sed -ne ' s|^/dev/\([^ ]*\).*$|\1|p'`
     30MOUNTPOINT=`echo "$MOUNT" | sed -ne 's|^.*\(/Volumes/.*\)$|\1|p'`
     31ditto -rsrc "$DSTROOT" "$MOUNTPOINT"
     32sudo chmod -R a+rX,u+w "$MOUNTPOINT"
     33hdiutil detach $DISK
     34hdiutil resize -sectors min "$DMG"
     35hdiutil convert "$DMG" -format UDBZ -o "z$DMG"
     36mv "z$DMG" "$DMG"
     37hdiutil internet-enable "$DMG"
    3838# scp "$DMG" ainaz:web/nriley/software/
    3939:
Note: See TracChangeset for help on using the changeset viewer.