Skip to content

Instantly share code, notes, and snippets.

Pete Scopes pdscopes

  • Leeds, UK
Block or report user

Report or block pdscopes

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@w00fz
w00fz / sphp.sh
Last active Mar 24, 2020
PHP switcher
View sphp.sh
#!/bin/bash
# Check if command was ran as root.
if [[ $(id -u) -eq 0 ]]; then
echo "The command \"sphp\" should not be executed as root or via sudo directly."
echo "When a service requires root access, you will be prompted for a password as needed."
exit 1
fi
# Usage
@WebDevStu
WebDevStu / list manager
Last active Jun 20, 2016
Tea dog list manager
View list manager
Array.prototype.slice.call(document.querySelectorAll('ul, ol').forEach(function (list) {
var item = document.createElement('li');
Item.innerHTML = "Brew!";
list.insertBefore(item, list.firstChild);
});
You can’t perform that action at this time.