This file contains 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
$file = __DIR__.’/orders/orders.xml’; | |
if (file_exists($file)) { | |
exit(); | |
} | |
set_time_limit(0); | |
ini_set(‘memory_limit’, ’1024M’); | |
include_once “../app/Mage.php”; | |
umask (0); | |
//Mage::app(‘default’); |
This file contains 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 | |
apt-get update | |
apt-get install -y git-core autoconf bison libxml2-dev libbz2-dev libmcrypt-dev libcurl4-openssl-dev libltdl-dev libpng-dev libpspell-dev libreadline-dev | |
mkdir -p /etc/php7/conf.d | |
mkdir -p /etc/php7/cli/conf.d | |
mkdir /usr/local/php7 | |
cd /tmp | |
git clone https://github.com/php/php-src.git --depth=1 | |
cd php-src | |
./buildconf |
This file contains 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/sh | |
# usage: | |
# ./modman-generator module-dir-name | |
cd $1 | |
echo "Generating magento modman file in $1" | |
rm modman | |
find * -type f -not -iwholename 'modman' -exec echo {} {} >> modman \; |
This file contains 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 | |
dir1="/tmp/dir1" | |
dir2="/tmp/dir2" | |
IFS=$'\n' | |
for file in $(grep -Ilsr -m 1 '.' "$dir1"); do diff -q --exclude="cache" "$file" "${file/${dir1}/${dir2}}" 2> /dev/null; done |
This file contains 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
rsync \ | |
--verbose \ | |
--progress \ | |
--stats \ | |
--compress \ | |
--rsh=/usr/bin/ssh \ | |
--recursive \ | |
--times \ | |
--perms \ | |
--links \ |
This file contains 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
<?php | |
$attribute_value = Mage::getResourceSingleton('catalog/product')->getAttributeRawValue($productId, 'attribute_code', Mage::app()->getStore()); | |
echo $attribute_value; |
This file contains 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
mkdir demo | |
cd demo | |
sudo wget http://www.magentocommerce.com/downloads/assets/1.9.0.1/magento-1.9.0.1.tar.gz | |
sudo wget http://www.magentocommerce.com/downloads/assets/1.9.0.0/magento-sample-data-1.9.0.0.tar.gz | |
tar -zxvf magento-1.9.0.1.tar.gz | |
tar -zxvf magento-sample-data-1.9.0.0.tar.gz | |
rsync -a magento-sample-data-1.9.0.0/media/* magento/media/ | |
mv magento-sample-data-1.9.0.0/magento_sample_data_for_1.9.0.0.sql magento/data.sql | |
mv magento/* magento/.htaccess . | |
chmod o+w var var/.htaccess app/etc |