Skip to content

Instantly share code, notes, and snippets.

View pborreli's full-sized avatar

Pascal Borreli pborreli

View GitHub Profile
@pborreli
pborreli / bigquery
Last active August 29, 2015 13:59
Anyone know how I can run some analytics on GitHub repos? Looking to count # of PR’s merged/closed by me this month
SELECT
COUNT(payload_pull_request_number) as counter, payload_pull_request_merged as merged
FROM [githubarchive:github.timeline]
WHERE type="PullRequestEvent"
AND actor = 'parkr'
AND payload_action = 'closed'
AND repository_name = 'jekyll'
AND PARSE_UTC_USEC(created_at) >= PARSE_UTC_USEC('2014-04-01 00:00:00')
GROUP BY merged;
### Keybase proof
I hereby claim:
* I am pborreli on github.
* I am pborreli (https://keybase.io/pborreli) on keybase.
* I have a public key whose fingerprint is E171 699B D7D7 E75C 9784 4930 7DB5 FAEA 91EE 3C75
To claim this, I am signing this object:
lingustique -> linguistique
vraiement -> vraiment
suffisament -> suffisamment
video -> vidéo
s'accomoder -> s'accommoder
connnu -> connu
le client envoit une requête -> le client envoie une requête
négoicer -> négocier
la lui envoit -> la lui envoie
fontionne -> fonctionne
<?php
/**
The modifications to this class caches in APC all the file system scans that symfony does to find plugins paths, configurations files, modules, etc.
**/
class frontendConfiguration extends sfApplicationConfiguration
{
@pborreli
pborreli / Configuration.class.php
Created April 28, 2010 17:01
adding ":" to all labels and "*" to all required fields inside symfony 1.3+ forms
<?php
class privateConfiguration extends sfApplicationConfiguration
{
public function configure()
{
$this->dispatcher->connect('form.post_configure', array($this, 'listenToFormPostConfigure'));
}
/**
@pborreli
pborreli / import
Created May 10, 2010 14:42
Dealing with mass import in doctrine/pdo using pcntl_fork
<?php
class importTask extends sfTask
{
protected function execute($arguments = array(), $options = array())
{
$xml = simplexml_load_file('file');
$users = array();
foreach ($xml->users as $user)
{
@pborreli
pborreli / *Configuration.class.php
Created September 1, 2010 15:52
removing admin gen css files at app/project level
<?php
class privateConfiguration extends sfApplicationConfiguration {
public function configure() {
$this->dispatcher->connect('view.configure_format', array($this, 'listenToViewConfigureFormatEvent'));
}
@pborreli
pborreli / Configuration.class.php
Created September 13, 2010 16:12
how to replace a specific widget by another for all generated forms in symfony
<?php
class xxxConfiguration extends sfXxxConfiguration
{
public function setup()
{
$this->dispatcher->connect('command.filter_options', array($this, 'filterCommandOptions'));
}
@pborreli
pborreli / Configuration.class.php
Created September 14, 2010 18:29
how to remove "with_empty" checkbox for all generated formFilters in symfony 1.4
<?php
class xxxConfiguration extends sfXxxConfiguration
{
public function setup()
{
$this->dispatcher->connect('command.filter_options', array($this, 'filterCommandOptions'));
}
@pborreli
pborreli / ProjectConfiguration.class.php
Created September 16, 2010 11:23
disable drop-db task in symfony console
<?php
class ProjectConfiguration extends sfProjectConfiguration
{
public function setup()
{
$this->dispatcher->connect('command.filter_options', array($this, 'filterCommandOptions'));
}
/**