Awesome PHP has been relocated permanently to its own Github repository. No further updates will made to this gist.
Please open an issue for any new suggestions.
# If not running interactively, don't do anything | |
[ -z "$PS1" ] && return | |
# simple history browsing | |
export HISTCONTROL=erasedups | |
export HISTSIZE=10000 | |
shopt -s histappend | |
bind '"\e[A"':history-search-backward | |
bind '"\e[B"':history-search-forward |
Awesome PHP has been relocated permanently to its own Github repository. No further updates will made to this gist.
Please open an issue for any new suggestions.
#This is the "site config" for nginx | |
upstream django { | |
# Distribute requests to servers based on client IP. This keeps load | |
# balancing fair but consistent per-client. In this instance we're | |
# only using one uWGSI worker anyway. | |
ip_hash; | |
server unix:/tmp/uwsgi.sock; | |
} | |
server { |
<?php | |
// full path to text file | |
define("TEXT_FILE", "/home/www/default-error.log"); | |
// number of lines to read from the end of file | |
define("LINES_COUNT", 10); | |
function read_file($file, $lines) { | |
//global $fsize; |
The list would not be updated for now. Don't write comments.
The count of contributions (summary of Pull Requests, opened issues and commits) to public repos at GitHub.com from Wed, 21 Sep 2022 till Thu, 21 Sep 2023.
Because of GitHub search limitations, only 1000 first users according to amount of followers are included. If you are not in the list you don't have enough followers. See raw data and source code. Algorithm in pseudocode:
githubUsers
<?php | |
namespace com\indigloo\core { | |
use \com\indigloo\Configuration as Config; | |
use \com\indigloo\mysql\PDOWrapper; | |
use \com\indigloo\Logger as Logger; | |
/* | |
* custom session handler to store PHP session data into mysql DB |
<?php | |
/** | |
* Component class file. | |
* | |
* @link http://www.yiiframework.com/ | |
* @copyright Copyright © 2008-2012 Yii Software LLC | |
* @license http://www.yiiframework.com/license/ | |
*/ | |
namespace yii\base; |
<?php | |
/** | |
* Object class file. | |
* | |
* @link http://www.yiiframework.com/ | |
* @copyright Copyright © 2008-2012 Yii Software LLC | |
* @license http://www.yiiframework.com/license/ | |
*/ | |
namespace yii\base; |
L1 cache reference ......................... 0.5 ns
Branch mispredict ............................ 5 ns
L2 cache reference ........................... 7 ns
Mutex lock/unlock ........................... 25 ns
Main memory reference ...................... 100 ns
Compress 1K bytes with Zippy ............. 3,000 ns = 3 µs
Send 2K bytes over 1 Gbps network ....... 20,000 ns = 20 µs
SSD random read ........................ 150,000 ns = 150 µs
Read 1 MB sequentially from memory ..... 250,000 ns = 250 µs
# /etc/network/interfaces | |
# | |
auto lo | |
iface lo inet loopback | |
# device: eth0 | |
iface eth0 inet manual | |
# IPv4 bridge | |
# (connect ONLY your firewall/router KVM instance here, this is the WAN device!) |