Created
April 18, 2011 03:17
-
-
Save nojimage/924753 to your computer and use it in GitHub Desktop.
create eZ Publish design extension
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# help print | |
function print_usage { | |
echo "" | |
echo "$0 <extension_name>" | |
} | |
if [ $# != 1 ]; then | |
print_usage | |
exit 1 | |
fi | |
EXTENSION_NAME=$1 | |
# | |
EXTENSION_ROOT=extension/${EXTENSION_NAME} | |
EXTENSION_DESIGN=${EXTENSION_ROOT}/design/${EXTENSION_NAME} | |
EXTENSION_SETTINGS=${EXTENSION_ROOT}/settings | |
if [ -d ${EXTENSION_ROOT} ]; then | |
echo "${EXTENSION_ROOT} already exists." | |
exit 1 | |
fi | |
# | |
mkdir -p $EXTENSION_DESIGN | |
mkdir $EXTENSION_DESIGN/images \ | |
$EXTENSION_DESIGN/javascript \ | |
$EXTENSION_DESIGN/override \ | |
$EXTENSION_DESIGN/stylesheets \ | |
$EXTENSION_DESIGN/templates | |
mkdir $EXTENSION_SETTINGS | |
# | |
echo "<?php /* | |
[ExtensionSettings] | |
DesignExtensions[]=${EXTENSION_NAME} | |
*/ ?>" > $EXTENSION_SETTINGS/design.ini.append.php |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment