This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
parse_git_branch() { | |
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/' | |
} | |
PS1='${debian_chroot:+($debian_chroot)}\[\033[1;31m\]\u\[\033[1;37m\]@\[\033[1;32m\]\h\[\033[1;37m\]:\[\033[1;36m\]\w \[\033[1;35m\]$(parse_git_branch) \[\033[1;33m\]\$ \[\033[0m\]' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Super simple class for logging. Generates regular logs and csv files | |
* @package lightLogger | |
* @author Kevin Chappell <[email protected]> | |
* @license http://opensource.org/licenses/MIT The MIT License (MIT) | |
* @since lightLogger .5 | |
*/ | |
/** |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Get an array of all user data | |
* @param string|int $user_id | |
* @return array merged array of user meta and data | |
*/ | |
function get_user_data( $user_id ){ | |
$user_data = (array) get_userdata( $user_id )->data; | |
$user_meta = array_map( function( $item ){ return $item[0]; }, (array) get_user_meta( $user_id ) ); | |
return array_merge( $user_data, $user_meta ); |
NewerOlder