Skip to content

Instantly share code, notes, and snippets.

View euperia's full-sized avatar

Andrew McCombe euperia

View GitHub Profile
@trovster
trovster / Dockerfile
Created August 1, 2018 11:57
Laravel in Docker
FROM php:5.6-apache
# Install gd, iconv, mbstring, mcrypt, mysql, soap, sockets, zip, and zlib extensions
# see example at https://hub.docker.com/_/php/
RUN apt-get update && apt-get install -y \
libbz2-dev \
libfreetype6-dev \
libgd-dev \
libjpeg62-turbo-dev \
libmcrypt-dev \
@trovster
trovster / development.sh
Last active December 26, 2021 14:33
Starting point for a script to setup development environment (MAMP)
#!/bin/sh
# chmod a+x development.sh
# General functionality
brew install git
brew install openssl
brew install node
brew install npm
brew install yarn
brew install bat
@trovster
trovster / software.sh
Last active January 8, 2020 12:27
Install software via CLI
#!/bin/sh
# chmod a+x software.sh
# Install Brew
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew tap homebrew/core
brew tap homebrew/cask
brew tap homebrew/cask-drivers
@avandrevitor
avandrevitor / .editorconfig
Last active May 11, 2023 05:29 — forked from Konafets/.editorconfig
PSR-2 Editorconfig Template
# EditorConfig is awesome: http://EditorConfig.org
# top-most EditorConfig file
root = true
# All PHP files MUST use the Unix LF (linefeed) line ending.
# Code MUST use an indent of 4 spaces, and MUST NOT use tabs for indenting.
# All PHP files MUST end with a single blank line.
# There MUST NOT be trailing whitespace at the end of non-blank lines.
[*]
@balloz
balloz / 0001-Fixed-1.9.3-search.patch
Created October 13, 2016 12:32
Magento 1.9.3 fixed search
From d48811b478c59299eacce45c49f2d3bb25291151 Mon Sep 17 00:00:00 2001
From: Bas Mostert <bas@iweb.co.uk>
Date: Thu, 13 Oct 2016 13:30:37 +0100
Subject: [PATCH] Fixed 1.9.3 search
---
.../Mage/CatalogSearch/Model/Resource/Fulltext.php | 56 +++++++++++-----------
.../Model/Resource/Fulltext/Collection.php | 3 +-
2 files changed, 30 insertions(+), 29 deletions(-)
@spalladino
spalladino / mysql-docker.sh
Created December 22, 2015 13:47
Backup and restore a mysql database from a running Docker mysql container
# Backup
docker exec CONTAINER /usr/bin/mysqldump -u root --password=root DATABASE > backup.sql
# Restore
cat backup.sql | docker exec -i CONTAINER /usr/bin/mysql -u root --password=root DATABASE
@vpietri
vpietri / datataflow.php
Last active June 19, 2020 16:09
Magento shell script to run dataflow from the command line
<?php
require_once 'abstract.php';
/**
* Magento Dataflow Shell Script
*
* This file should be save in the shell directory of Magento
* Basic usage samples:
* php dataflow.php
* php dataflow.php list
@insom
insom / my.cnf
Created June 29, 2015 08:23
Very low memory MySQL
[mysqld]
skip-innodb
default-storage-engine=myisam
default-tmp-storage-engine=myisam
query_cache_size=0
max_connections=10
key_buffer_size=8
thread_cache_size=0
host_cache_size=0
thread_stack=131072
@vitorbritto
vitorbritto / add_php_brew.md
Last active September 26, 2018 14:19
Install PHP with HomeBrew

Install PHP with HomeBrew

Complete Guide / Isseus / Common Problems: https://github.com/Homebrew/homebrew-php

Installing PHP 5.6

# Install PHP with PHP-FPM and excluding snmp
brew install -v homebrew/php/php56 --with-fpm --without-snmp

Setting up PHP 5.6

@frankdejonge
frankdejonge / example.php
Created October 31, 2014 15:01
Flysystem Download from FTP
<?php
$ftp = new League\Flysystem\Filesystem(new League\Flysystem\Adapter\Ftp($settings));
$local = new League\Flysystem\Filesystem(new League\Flysystem\Adapter\Local($path));
$local->write($destination, $ftp->read($source));