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 | |
$_SERVER['HTTP_HOST'] = 'magento.local'; | |
require 'app/Mage.php'; | |
umask(0); | |
$request = new Mage_Core_Controller_Request_Http('http://magento.local/guitars-basses'); | |
Mage::run('', 'store', array('request' => $request)); |
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 | |
if [ -e "$1" ]; then | |
dataset=$(cat $1) | |
elif [ ! -z $1 ]; then | |
dataset=$@ | |
else | |
exit 1 | |
fi |
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 | |
GC_OPTS=$@ | |
for item in `git clean $@ | grep -v git-iclean | grep "Would remove" | cut -d' ' -f 3`; do | |
rm -ir $item | |
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
#!/bin/sh | |
# Run from /docroot/app/design/[adminhtml|frontend|install]/[package]/[theme] | |
vimdiff ../../base/default/${1} ${1} |
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 | |
require 'app/Mage.php'; | |
umask(0); | |
Mage::app(); | |
$attribute = Mage::getModel('catalog/entity_attribute')->loadByCode( | |
Mage::getModel('eav/entity')->setType('catalog_product')->getTypeId(), | |
'tiger_cost' | |
); |
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
for i in `git ls-files --other --exclude-standard`; do rm -ir $i; 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
<?php | |
class X_TigerEDI_Model_Observer_850 extends X_TigerEDI_Model_Observer | |
{ | |
protected $_ediID = 850; | |
private $_ediFiles = array(); | |
/** |
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
current_path = File.dirname(__FILE__) | |
parent_path = File.dirname(current_path) | |
project = File.basename(current_path) | |
namespace :mage do | |
desc 'Clear the Magento cache.' | |
task :cc do | |
sh %{cd #{current_path} && rm -rf var/cache/*} | |
end |
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 | |
/* @var $tree Mage_Catalog_Model_Resource_Category_Tree */ | |
$tree = Mage::getResourceModel('catalog/category_tree'); | |
/* 594 = 616, 597 = 856 */ | |
$storeCategories = $this->getStoreCategories(); | |
$storeCategories->delete($storeCategories->searchById(594)); | |
$storeCategories->delete($storeCategories->searchById(597)); | |
$node = $tree->loadNode(616); |
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
var/* | |
media/* | |
pkginfo/* | |
config/* | |
app/etc/local.xml | |
includes/* | |
Capfile | |
.idea/* | |
.DS_Store | |
*.*~ |
OlderNewer