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
[Fri, 09 Apr 2010 23:40:08 -0700] ERROR: execute[start-atd] (/etc/chef/recipes/cookbooks/ey-base/recipes/default.rb line 104) had an error: | |
/etc/init.d/atd restart | |
returned 1, expected 0 | |
---- Begin output of | |
/etc/init.d/atd restart | |
---- | |
STDOUT: * ERROR: cannot start atd as sysklogd could not start | |
STDERR: | |
---- End output of |
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
/* | |
1) Open the github page using the account from where you have to copy the watched repos | |
2) In "watched repos" block, click on "All repositories" => this will show a list of all repos this account is watching | |
3) Open webkit console and paste this codebase. Replace TARGET_USERNAME & TARGET_PASSWORD with the auth of profile in which you finally want to watch the repos. | |
4) Wait for all the network calls to complete. | |
*/ | |
function watch(repoName) { |
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 ################ | |
function parse_git_branch { | |
ref=$(git symbolic-ref HEAD 2> /dev/null) || return | |
echo "("${ref#refs/heads/}")" | |
} | |
RED="\[\033[0;31m\]" | |
YELLOW="\[\033[0;33m\]" | |
GREEN="\[\033[0;32m\]" |
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
<div class="bubble" style="background: red; border-color: red;">test</div> | |
<div class="bubble" style="background: green; border-color: green;">test</div> | |
<style> | |
.bubble { | |
margin: 50px; | |
padding: 50px; | |
position: relative; | |
} | |
.bubble:after { |
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
############ WORK IN PROCESS ############ | |
# -- Copy (append) the following script to your ~/.bashrc file and restart console -- | |
## Workflow ## | |
# Suppose the current deploy branch is deploy_x_y | |
# Suppose you have to start work on Bug #100 | |
# Run "bbcreate 100" => a new branch 100_bug will be created out of deploy_x_y and will be checked out (ready to start work) | |
# You work and finish the changes in your 100_bug branch | |
# Run "bbpush" to add + commit + push your changes into 100_bug branch. Commit log will be "Fixes for #100" | |
# You can do bbpush multiple times you like |
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
saveSurvey : function(survey, successCb, errorCb) { | |
errorCb = errorCb || function(){}; | |
// save the user | |
this.save( | |
{survey : survey}, | |
{ | |
success : function() {successCb();}, | |
error : function() {errorCb();} | |
} |
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 | |
require_once('../site_config.php'); // include the required classes to make MongoBase class work | |
class MongoFoo extends Mongo_ModelBase { | |
} | |
for($i=0; $i<100; $i++) | |
{ | |
$mFoo = new MongoFoo(); | |
} |
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
<i class="macbook"></i> |
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
require "freshdesk" | |
client = Freshdesk.new("http://domain.freshdesk.com/", "username", "password") | |
client.response_format = "json" | |
ticket = client.post_tickets({:email => "[email protected]", :description => "description", :subject => "subject", :status => 1, :priority => 1}) |
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
import json | |
from datetime import datetime, timedelta | |
# Copies logic from https://www.quantconnect.com/tutorials/strategy-library/fundamental-factor-long-short-strategy | |
# Algo storing - https://www.quantconnect.com/docs/algorithm-framework/algorithm-scoring | |
class ChartMillBackTester(QCAlgorithm): | |
def Initialize(self): | |
self.SetCash(1000*1000) # Are't we rich? :D |
OlderNewer