Skip to content

Instantly share code, notes, and snippets.

View neemzy's full-sized avatar

Tom Panier neemzy

View GitHub Profile
@neemzy
neemzy / counter.php
Last active January 9, 2018 10:40
Counter to freedom
<?php
$naow = new DateTime(date('Y-m-d').' 00:00:00');
$last = new DateTime('2017-09-08 00:00:00'); // date of last working day
/**
* @param DateTime $date
*
* @return bool
*/
@neemzy
neemzy / outdated-deps.php
Last active December 9, 2016 09:41
PHP script to make "(composer|npm) outdated" smarter
#!/usr/bin/php
<?php
// We will filter original outputs by ignoring packages for which we aren't using the latest major version,
// as well as branch references and packages installed straight from git repos.
$isUpToDateComposer = true;
$isUpToDateNpm = true;
// Composer
if (file_exists('composer.json')) {

Keybase proof

I hereby claim:

  • I am neemzy on github.
  • I am neemzy (https://keybase.io/neemzy) on keybase.
  • I have a public key whose fingerprint is BEDA 3CA7 A920 3CFD ADED 838A 7487 7132 0A28 1BBA

To claim this, I am signing this object:

@neemzy
neemzy / Gruntfile.js
Last active December 31, 2015 23:38
Un p'tit essai sur une génération de menu récursif avec Nunjucks. Bon c'est fait à l'arrache hein, à développer (sans mauvais jeu de mots), mais sur le principe ça marche comme je l'imaginais :)
module.exports = function(grunt)
{
// Nunjucks
grunt.registerTask('nunjucks', 'compilation du template', function(src, dest) {
var nunjucks = require('nunjucks');
grunt.file.write(
dest,
nunjucks.render(