This file contains 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
// All non-merge commits | |
reg = /^(.+?)(\n|$)/; ' * ' + Array.prototype.slice.call(document.querySelectorAll('#commits_bucket .Details a')).map(el => el.title).filter(title => title && title.indexOf('Merge') !== 0).map(title => { var mm = title.match(reg); return mm && mm[1]; }).join("\n * "); | |
// Only merge commits | |
reg = /^[^#]+(#[0-9]+)[^\n]+\n\n((?:.|\n)+)$/; ' * ' + Array.prototype.slice.call(document.querySelectorAll('#commits_bucket .Details a:first-of-type')).map(el => el.title).filter(title => title.indexOf('Merge') === 0).map(title => { var mm = title.match(reg); return mm && mm[2] + ' (' + mm[1] + ')'; }).filter(Boolean).join("\n * "); |
This file contains 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
foreach ($items as $item) | |
{ | |
if (!$item->isActive()) | |
continue; | |
// do stuff with $item | |
} |
This file contains 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 | |
// If these aren't defined, define them so the official API client doesn't cry. | |
if (!defined('CURLOPT_USERAGENT')) | |
define('CURLOPT_USERAGENT', 'CURLOPT_USERAGENT'); | |
if (!defined('CURLOPT_CONNECTTIMEOUT')) | |
define('CURLOPT_CONNECTTIMEOUT', 'CURLOPT_CONNECTTIMEOUT'); | |
if (!defined('CURLOPT_TIMEOUT')) | |
define('CURLOPT_TIMEOUT', 'CURLOPT_TIMEOUT'); | |
if (!defined('CURLOPT_RETURNTRANSFER')) |