- Open the Terminal Application
- Type in
sudo -i
and type in your Mac Administrator account password.sudo
gives you root level or administrator level privileges.
dsconfigad -show
static public function slugify($text) | |
{ | |
// replace non letter or digits by - | |
$text = preg_replace('~[^\\pL\d]+~u', '-', $text); | |
// trim | |
$text = trim($text, '-'); | |
// transliterate | |
$text = iconv('utf-8', 'us-ascii//TRANSLIT', $text); |
sudo -i
and type in your Mac Administrator account password. sudo
gives you root level or administrator level privileges.dsconfigad -show
#!/bin/sh | |
if [[ $# -ne 4 ]] | |
then | |
echo "Usage $0 <repository path> <Old Committer Email> <New Committer Name> <New Committer Email>" # missing parameters | |
exit 2 | |
fi | |
cd $1 |
#!/bin/bash | |
if [[ $# -ne 3 ]] | |
then | |
echo "Usage $0 <repository path> <commit hash> <branch name>" # missing parameters | |
exit 2 | |
fi | |
cd $1 | |
git checkout --orphan temp $2 | |
git commit -m "Initial Commit" |
#!/bin/bash | |
if [[ $# -ne 1 ]] | |
then | |
echo "Usage $0 path/to/your/directory" # path parameter missing | |
exit 2 | |
fi | |
directory=$1 |
#!/usr/bin/env bash | |
# checks if branch has something pending | |
function parse_git_dirty() { | |
git diff --quiet --ignore-submodules HEAD 2>/dev/null; [ $? -eq 1 ] && echo "*" | |
} | |
# gets the current git branch | |
function parse_git_branch() { | |
git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e "s/* \(.*\)/\1$(parse_git_dirty)/" |
DROP FUNCTION IF EXISTS UPDATE_SLUG; | |
DELIMITER | | |
CREATE FUNCTION UPDATE_SLUG(old_slug TEXT) | |
RETURNS TEXT | |
BEGIN | |
DECLARE slug_maxlength INT DEFAULT 64; | |
DECLARE cut_length INT DEFAULT 4; | |
DECLARE new_slug TEXT; | |
DECLARE count_duplicate INT; | |
DECLARE slugcount INT; |
DROP FUNCTION IF EXISTS UPDATE_MEMBER_GUID; | |
DELIMITER | | |
CREATE FUNCTION UPDATE_MEMBER_GUID(old_slug TEXT) | |
RETURNS TEXT | |
BEGIN | |
DECLARE slug_maxlength INT DEFAULT 64; | |
DECLARE cut_length INT DEFAULT 4; | |
DECLARE new_slug TEXT; | |
DECLARE count_duplicate INT; | |
DECLARE slugcount INT; |
DROP FUNCTION IF EXISTS UPDATE_TEAM_GUID; | |
DELIMITER | | |
CREATE FUNCTION UPDATE_TEAM_GUID(old_slug TEXT) | |
RETURNS TEXT | |
BEGIN | |
DECLARE slug_maxlength INT DEFAULT 64; | |
DECLARE cut_length INT DEFAULT 4; | |
DECLARE new_slug TEXT; | |
DECLARE count_duplicate INT; | |
DECLARE slugcount INT; |
<?php | |
// Rules for Laravel Code Standard | |
$rules = [ | |
'@PSR2' => true, | |
// PHP arrays should be declared using the configured syntax. | |
'array_syntax' => [ | |
'syntax' => 'short', //whether to use the long or short array syntax; | |
], |