View .git__hooks__pre-commit
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
#!/usr/bin/python | |
""" | |
File: .git/hooks/pre-commit | |
Referencing current branch in github README.md[1] | |
This pre-commit hook[2] updates the README.md file's | |
Travis badge with the current branch. Gist at[4]. | |
[1] http://stackoverflow.com/questions/18673694/referencing-current-branch-in-github-readme-md |
View lndupes.py
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
#!/usr/bin/env python | |
# source: https://gist.github.com/filipenf/e9901883d66b8da65c151cf674e5f2a9 | |
# | |
# Reads fdupes(-r -1) output and create relative symbolic links for each duplicate | |
# usage: fdupes -r1 . | ./lndupes.py | |
import os | |
from os.path import dirname, relpath, basename, join | |
import sys | |
import shlex |
View magehost_php7_fix.sh
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
# | |
# Copyright 2017 MageHost.pro | |
# | |
cd ~/httpdocs | |
test -d .git && { git add -A; git commit -a -m 'Uncommitted changes on server'; } | |
test -d .modman || modman init | |
modman clone --copy --force https://github.com/Inchoo/Inchoo_PHP7 -b 1.9.2.4 | |
n98-magerun.phar cache:clean | |
test -d .git && { git add -A; git commit -a -m 'Installed Inchoo_PHP7 via modman'; } | |
wget https://gist.githubusercontent.com/renttek/29beaaa1e90909639501/raw/be5df0b33b72cdc2ab037d374802c53ccba066df/0001-BUGIFX-Magento-Zend-Framework-1-PHP5.6.patch |
View find_cacheable_false.sh
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
#### by MageHost.pro #### | |
# execute in Magento 2 root: | |
find vendor app -regextype 'egrep' -type f -regex '.*/layout/.*\.xml' -not -regex '.*(vendor/magento/|/checkout_|/catalogsearch_result_|/dotmailer).*' | xargs grep --color -n -e 'cacheable="false"' |
View convertImages.sh
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 | |
# convertImages.sh | |
# Authors: Peter Jaap Blaakmeer (elgentos.nl) & Jeroen Vermeulen (magehost.pro) | |
# https://gist.github.com/peterjaap/7080989 | |
# https://gist.github.com/jeroenvermeulen/feb819799dea3d74ae9c | |
NEWQUALITY=90 | |
NEWWIDTH=2000 | |
DIRECTORY=$HOME/httpdocs/media/catalog/product/ |
View Magento_Hosting_Benchmark_Results.txt
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
#### Magento Hosting Performance Benchmarks | |
#### Executed by: JeroenVermeulen.eu / MagentoHosting.pro | |
## Example test command for 5 concurrent users hitting as fast as possible: | |
## siege --concurrent=5 --file=urls.txt --log=log.txt --time=60s --quiet --benchmark --internet | |
## The file urls.txt contains 5029 URLs based on sitemap.xml. | |
## Magento contains 5933 Total products. | |
## Magento has 4697 Enabled products. | |
## |
View jv_clean_product_images.php
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
#!/usr/bin/env php | |
<?php | |
/** | |
* mh_remove_unused_product_images.php | |
* | |
* NOTICE OF LICENSE | |
* | |
* This source file is subject to the Open Software License (OSL 3.0) | |
* that is bundled with this package in the file LICENSE.txt. | |
* It is also available through the world-wide-web at this URL: |