Skip to content

Instantly share code, notes, and snippets.

View MagePsycho's full-sized avatar

magepsycho MagePsycho

View GitHub Profile
@molotovbliss
molotovbliss / Mb-M2-resources.md
Created March 19, 2018 17:29
Magento2 Resources List; Needing a place to keep a list of all the tools/references used during Magento development.
@sonnetmia
sonnetmia / mysql-create-db-user.sh
Last active November 5, 2023 05:42 — forked from MagePsycho/mysql-create-db-user.sh
Bash Script: Create MySQL Database & User
#!/bin/bash
#
# Script to create MySQL db + user
#
# @author Raj KB <[email protected]>
# @website http://www.magepsycho.com
# @version 0.1.0
# Usage chmod +x ./mysql-create-db-user.sh
# ./mysql-create-db-user.sh --host=localhost --database=test-db --user=test-user
<?php
/**
*
* @author Raj KB<[email protected]>
* @website http://www.magepsycho.com
* @extension MassImporterPro: Pricing - http://www.magepsycho.com/mass-importer-pro-price-importer-regular-special-tier-group.html
*/
ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);
@MagePsycho
MagePsycho / mysql-create-db-user.sh
Last active January 8, 2025 00:09
Bash Script: Create MySQL Database & User - https://blog.magepsycho.com/
#!/bin/bash
#
# Script to create MySQL db + user
#
# @author Raj KB <[email protected]>
# @website http://www.magepsycho.com
# @version 0.1.0
################################################################################
@iancassidyweb
iancassidyweb / 2.1.6-Image-Resize-Patch
Created May 19, 2017 09:20
Magento 2.1.6 - Image Resizer Patch - Allow CLI Override
Index: www/vendor/magento/module-catalog/Helper/Image.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- www/vendor/magento/module-catalog/Helper/Image.php
+++ www/vendor/magento/module-catalog/Helper/Image.php
@@ -494,6 +494,6 @@
protected function isScheduledActionsAllowed()
{
@hn-support
hn-support / curl_speedtest.sh
Last active October 9, 2017 12:49
Test urls using curl
#!/bin/bash
# This script is a very basic curl utility to analyze urls.
# To use it, download the file, make it executable, and run:
# ./curl_speedtest.sh https://www.byte.nl
URL="$1"
if [ "x${URL}" == "x" ] || [[ ! "${URL}" =~ "http" ]] ; then
echo "Usage: $0 <url>"
exit 1
@hn-support
hn-support / env.php
Last active November 4, 2022 22:23
magento2 configuration
<?php
return array (
'backend' => array (
'frontName' => 'webshop_admin',
),
'crypt' => array (
'key' => '355fb68f9e21189d170c1d759616cd58',
),
'db' => array (
@ProcessEight
ProcessEight / Testing in Magento 2.md
Last active February 11, 2025 09:03
M2: Notes on setting up PHPUnit and writing/troubleshooting tests in Magento 2
@ziadoz
ziadoz / install.sh
Last active February 8, 2025 16:04
Install Chrome, ChromeDriver and Selenium on Ubuntu 16.04
#!/usr/bin/env bash
# https://developers.supportbee.com/blog/setting-up-cucumber-to-run-with-Chrome-on-Linux/
# https://gist.github.com/curtismcmullan/7be1a8c1c841a9d8db2c
# https://stackoverflow.com/questions/10792403/how-do-i-get-chrome-working-with-selenium-using-php-webdriver
# https://stackoverflow.com/questions/26133486/how-to-specify-binary-path-for-remote-chromedriver-in-codeception
# https://stackoverflow.com/questions/40262682/how-to-run-selenium-3-x-with-chrome-driver-through-terminal
# https://askubuntu.com/questions/760085/how-do-you-install-google-chrome-on-ubuntu-16-04
# Versions
CHROME_DRIVER_VERSION=`curl -sS https://chromedriver.storage.googleapis.com/LATEST_RELEASE`
@hn-support
hn-support / cache-warmer.sh
Created January 11, 2017 12:47
A cache warmer in bash using curl
#!/bin/bash
if [ "$#" -ne 1 ] || [ "x$1" == "x" ] ; then
echo "Usage: $0 <sitemap.xml>"
exit 0;
fi
if [ ! -f "$1" ]; then
echo "Sitemap file $1 not found! Exit!"
exit 1