Skip to content

Instantly share code, notes, and snippets.

@hungneox
hungneox / WIN10.MD
Last active June 25, 2024 14:17
How Make a Windows 10 USB Using Your Mac - Build a Bootable ISO From Your Mac's Terminal

Most new PCs don't come with DVD drives anymore. So it can be a pain to install Windows on a new computer.

Luckily, Microsoft makes a tool that you can use to install Windows from a USB storage drive (or "thumbdrive" as they are often called).

But what if you don't have a second PC for setting up that USB storage drive in the first place?

In this tutorial we'll show you how you can set this up from a Mac.

Step 1: Download the Windows 10 ISO file

You can download the ISO file straight from Windows. That's right - everything we're going to do here is 100% legal and sanctioned by Microsoft.

@molotovbliss
molotovbliss / README.md
Last active March 6, 2024 14:17
Speed up warden for faster importing of large sql dumps.

Speed up warden for faster importing of large sql dumps.

  1. Add the innodb options to the warden/environments/magento2.base.yml docker-compose YML file.
  2. Restart warden environment warden env down && warden sync stop && warden env up -d && warden sync start
  3. Import the .sql file with warden db import.
  4. Remove options & restart warden enviornment once import completed.

Why these settings

  • innodb_buffer_pool_size : Will cache frequently read data
@Hailong
Hailong / Index.php
Last active November 25, 2020 01:23
Fix ShipStation plugin for Magento 2.3
<?php
namespace Auctane\Api\Controller\Auctane;
use Exception;
use Magento\Framework\App\CsrfAwareActionInterface;
use Magento\Framework\App\Request\InvalidRequestException;
use Magento\Framework\App\RequestInterface;
class Index extends \Magento\Framework\App\Action\Action implements CsrfAwareActionInterface
{
@tylers-username
tylers-username / .lando.yml
Last active September 1, 2020 08:34
Magento 2: Quick Lando Setup
#####
# Built & Tested against: v3.0.0-rc.16
#
# The first time that this project is launched, it will take Lando a while to get past "waiting until nginx service is ready"
# This is because Magento has not yet been setup and is 302-redirecting "/" to "/setup" while Lando is hoping for a "200"
# response. One the setup has completed Lando will show a ready-state much more quickly on the next start-up.
# Give this Lando project a unique name
name: m2-community
@robhrt7
robhrt7 / MySQL_5-7_macOS.md
Last active February 28, 2024 03:48 — forked from nrollr/MySQL_macOS_Sierra.md
Install MySQL 5.7 on macOS using Homebrew

This is a fork of original gist https://gist.github.com/nrollr/3f57fc15ded7dddddcc4e82fe137b58e, with slight changes on pointing to 5.7 version branch, instead of 8 (latest default of MySQL in Hombrew).

Install MySQL 5.7 on macOS

This procedure explains how to install MySQL using Homebrew on macOS (Sierra 10.12 and up)

Install Homebrew

  • Installing Homebrew is effortless, open Terminal and enter :
    $ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
  • Note: Homebrew will download and install Command Line Tools for Xcode 8.0 as part of the installation process.
@tayhimself
tayhimself / php-int.md
Created July 13, 2018 22:10
PHP intl extension using macOS 10.13 PHP 7.1.x

If you're using brew you need to do nothing. weprovide/valet-plus#127

If you're using the native macos PHP, make sure php is running fine, and see what modules are installed

$php -m

You will see a bunch of modules but they're missing intl

Go here and choose the install script you need to go https://php-osx.liip.ch/

@dunglas
dunglas / example.php
Created April 19, 2018 06:25
A minimalist GraphQL client for PHP
<?php
$query = <<<'GRAPHQL'
query GetUser($user: String!) {
user (login: $user) {
name
email
repositoriesContributedTo {
totalCount
}
@saurabheights
saurabheights / QuickSystemSetup.sh
Last active April 17, 2024 22:11
A gist to quickly setup ubuntu for your needs.
# Disable need to provide password for sudo. use only if you can lock system when afk.
sudo visudo
# Add below line to the end of file, where replace $USER with your system username.
$USER ALL=(ALL) NOPASSWD: ALL
# Install fzf for better reverse search
sudo apt install fzf
cat /usr/share/doc/fzf/README.Debian # For how to integrate with your shell
echo "source /usr/share/doc/fzf/examples/completion.bash" » ~/.bashrc
@GhazanfarMir
GhazanfarMir / Instructions.sh
Last active May 14, 2024 03:26
Install PHP7.2 NGINX and PHP7.2-FPM on Ubuntu 16.04
########## Install NGINX ##############
# Install software-properties-common package to give us add-apt-repository package
sudo apt-get install -y software-properties-common
# Install latest nginx version from community maintained ppa
sudo add-apt-repository ppa:nginx/stable
# Update packages after adding ppa
@xeptore
xeptore / Change_php_version_ubnutu.md
Last active February 5, 2021 11:07
How to downgrade/upgrade PHP versions on Ubuntu-based linux distros

Add Repo

sudo add-apt-repository ppa:ondrej/php
sudo apt-get update
sudo apt-get upgrade

Install PHP5.6

sudo apt-get install php5.6 php5.6-cli php5.6-common libapache2-mod-php5.6 php5.6-mysql php5.6-fpm php5.6-curl php5.6-gd php5.6-bz2 php5.6-mcrypt php5.6-json php5.6-tidy php5.6-mbstring php5.6-intl php-redis php-memcached php-gettext php-xdebug