Skip to content

Instantly share code, notes, and snippets.

View queval-j's full-sized avatar

Jean-Christophe Queval-Bourgeois queval-j

View GitHub Profile
@queval-j
queval-j / mac m1 - PHP SQLSRV for MAMP Pro
Created May 4, 2022 08:37
Install PHP SQLSRV for Mac M1 (ARM64)
# 1) Follow documentation
https://docs.microsoft.com/en-us/sql/connect/odbc/linux-mac/install-microsoft-odbc-driver-sql-server-macos?view=sql-server-ver15
## a) Instal unixodbc and tools
```bash
$> brew install autoconf automake libtool
$> brew install unixodbc
```
## b) Install msodbc
```bash
$> /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
@queval-j
queval-j / build.sh
Created August 17, 2020 19:39
Compile nginx 1.19 with push_stream / mod_zip / mod_headers / openssl with tls1_3
#!/usr/bin/bash
# Required yum install
# Vars
export BUILD_DIR=/tmp/nginx-build
# Script
echo "=== Custom NGINX ==="
echo "=> Build folder: $BUILD_DIR"
echo "0) Cleaning folder"
rm -rfv $BUILD_DIR
@queval-j
queval-j / remove.GMAILHeader.js
Created July 14, 2019 16:05
I created this snippet to print an email without the GMail header (email address / subject / number of messsage / Gmail Logo). This will give you only the content of the email and trigger the "print" modal.
function removeGMAILHeader() {
document.querySelector('table').remove();
document.querySelector('table').remove()
document.querySelectorAll('hr').forEach((node) => {node.remove()});
document.querySelector('table tbody tr').remove();
document.querySelector('table tbody tr').remove();
window.print()
};removeGMAILHeader();
@queval-j
queval-j / ezpublish_install.sh
Last active October 24, 2016 15:55
EZPublish 5 (EZPlatform) Install steps
# ./ezpublish_install.sh $folder_name
echo "== Project will be located at" $(pwd)"/$1 =="
sleep 2
echo "==> Create the project"
composer create-project --no-dev ezsystems/ezplatform
sleep 1
mv ezplatform $1
cd ./$1
echo "==> Composer install"
@queval-j
queval-j / install_intl.sh
Created September 29, 2016 15:18
[macOS Sierra] Install intl to MAMP 3
# You have to have ICU4C and PECL installed
# ICU4C : brew install icu4c
# PECL / PEAR : http://jason.pureconcepts.net/2012/10/install-pear-pecl-mac-os-x/
# Change the ICU_DIR by your ICU4C version