Skip to content

Instantly share code, notes, and snippets.

View rihardsgrig's full-sized avatar

Rihards Grigorjevs rihardsgrig

View GitHub Profile
@rihardsgrig
rihardsgrig / sphp
Last active June 8, 2023 13:36 — forked from Synchro/sphp
Easy Brew PHP-FPM switch
#!/usr/bin/env bash
latest="8.2"
versions=("7.4" "8.0" "8.1" "$latest")
valid=$(printf "|%s" "${versions[@]}")
switch="$1"
ERROR=$(tput setaf 1)
SUCCESS=$(tput setaf 2)
if [ -z "$switch" ]