Short manual on how to configure the server, so all instances are the same:
- PHP FPM
- nginx
- SSL configuration
- port configuration
- Uses the
public
folder for Symfony projects, modify paths to suit your needs - MySQL
import android.view.View | |
object ViewTouchSharing { | |
fun shareTouchEvents(vararg views: View, clickListener: (() -> Unit)? = null) { | |
views.firstOrNull()?.let { view -> | |
view.setOnClickListener { | |
clickListener?.invoke() | |
} | |
} |
#! /bin/bash | |
# | |
# Diffusion youtube avec ffmpeg | |
# Configurer youtube avec une résolution 720p. La vidéo n'est pas scalée. | |
VBR="2500k" # Bitrate de la vidéo en sortie | |
FPS="30" # FPS de la vidéo en sortie | |
QUAL="medium" # Preset de qualité FFMPEG | |
YOUTUBE_URL="rtmp://a.rtmp.youtube.com/live2" # URL de base RTMP youtube |
// Suppose you have 2 array and you want each value from array 2 to appear next to the value of array 1 with the same index... | |
$array1 = ['This', 'supposed', 'make', 'sentence']; | |
$array2 = ['is', 'to', 'a']; | |
$num1 = (count($array1) - 1) * 2; | |
$num2 = (count($array2) - 0) * 2; | |
$leftIndex = $num1 > 0 ? range(0, $num1, 2) : [0]; | |
$rightIndexes = $num2 > 2 ? range(1, $num2, 2) : [1]; |
# | |
# Installing Apache 2.4 and PHP 7.1 using Homebrew | |
# Credits @ https://gist.github.com/DragonBe/0faebe58deced34744953e3bf6afbec7 | |
# | |
# Note to self to manage httpd process: | |
# sudo brew services start|stop|restart httpd | |
# Install Xcode command line tools | |
xcode-select --install |
i=setInterval(()=>{(l=document.querySelectorAll('.diff-expander')).forEach(e=>{e.click()});l.length?{}:clearInterval(i)},1000); |