- Run "yii migrate --interactive=0" from "protected" dir.
- Check that "protected/runtime" and "www/assets" are writable by webserver process.
- Clear assets dir.
- Run unit tests and send an email to project members only if failed.
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 | |
// first you need to export all your time you want to sum up and copy to this script dir | |
$sum = 0; | |
$f = fopen('export_tasks.csv', 'r'); | |
if($f) | |
{ | |
while (($data = fgetcsv($f, 1000, ",")) !== FALSE) { | |
if(!isset($data[4])) | |
continue; |
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
git checkout . | |
git-clean -f |
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 | |
/** | |
* interview street test runner | |
* | |
* Test code should be in /test.php. | |
* Tests should be unpacked under /tests. | |
*/ | |
$dir=dirname(__FILE__) . "/tests"; | |
$di=new DirectoryIterator($dir); |
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
git filter-branch --commit-filter ' | |
if [ "$GIT_COMMITTER_NAME" = "Alex" ]; | |
then | |
GIT_COMMITTER_NAME="Alexander Makarov"; | |
GIT_AUTHOR_NAME="Alexander Makarov"; | |
GIT_COMMITTER_EMAIL="[email protected]"; | |
GIT_AUTHOR_EMAIL="[email protected]"; | |
git commit-tree "$@"; | |
else | |
git commit-tree "$@"; |
This gist is part of a blog post. Check it out at:
http://jasonrudolph.com/blog/2011/08/09/programming-achievements-how-to-level-up-as-a-developer
This one is samdark's personal list.
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 | |
/** | |
* Yii, simple HMVC | |
*/ | |
class HmvcController extends Controller | |
{ | |
public function actionIndex() | |
{ | |
echo $this->execute('/hmvc/do/id/123'); | |
} |
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 | |
/** | |
* Q: | |
* | |
* Hi, could please add this feature please. Here is my case, I have two themes | |
* and I have modules. How can one set each view file in the modules to use | |
* either one of the themes. Such if the view is admin use backoffice theme and | |
* if view is index use siteNew theme. I so someting like setBasePath and | |
* setBaseUrl but I don not know where they should be exactly. | |
* |
NewerOlder