Skip to content

Instantly share code, notes, and snippets.

View nitriques's full-sized avatar

Nicolas Brassard nitriques

View GitHub Profile
@lyrixx
lyrixx / HardCoreDebugLogger.php
Last active April 27, 2024 14:09
Hardcore Debug Logger
<?php
const STREAM_OPEN_FOR_INCLUDE = 128;
final class HardCoreDebugLogger
{
public static function register(string $output = 'php://stdout')
{
register_tick_function(function () use ($output) {
$bt = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS, 1);
@lelandbatey
lelandbatey / whiteboardCleaner.md
Last active April 25, 2024 02:01
Whiteboard Picture Cleaner - Shell one-liner/script to clean up and beautify photos of whiteboards!

Description

This simple script will take a picture of a whiteboard and use parts of the ImageMagick library with sane defaults to clean it up tremendously.

The script is here:

#!/bin/bash
convert "$1" -morphology Convolve DoG:15,100,0 -negate -normalize -blur 0x1 -channel RBG -level 60%,91%,0.1 "$2"

Results

@irazasyed
irazasyed / How-To Install Memcache on CentOS WHM-cPanel.md
Last active November 15, 2023 14:28
How-To: Install Memcache on CentOS (WHM/cPanel)

How-To: Install Memcache on CentOS (WHM/cPanel)

Without wasting much time, Let us get started!

Follow these simple instructions:

  • Step 1: Login into your WHM panel and using easyapache enable Memcache

  • Step 2: SSH into your server and fire this command yum install memcached.x86_64 php-pecl-memcache.x86_64

@soffes
soffes / Podfile
Created July 11, 2013 21:25
Everlapse Podfile
platform :ios, '6.0'
# Networking
pod 'AFNetworking'
# Localytics
pod 'Localytics-iOS-Client'
# Gradients
pod 'SAMGradientView'
@nitriques
nitriques / Chrome
Created May 8, 2013 17:11
Why chrome is not my best friend anymore...
Starting from version 26, Chrome as been making angry a lot...
Chrome
1. CSS3 animation are not as fluid as they used to be. IE10 is not more fluid than Chrome!
2. CSS3 gradiants are making the render glitchy: sometimes going under 5 FPS.
3. It seems like there is a problem with images cache: On the canvas, if you do not paint a image for one frame, then its cache gets deleted, which cause a performance problem (renders usually took 1 to 2 ms, but it jumps to 200 ms sometimes, and there's a blank in the devtools timeline. In the profile view, we only get (system) as feedback)
4. The video API throws errors when everything should be working fine. It plays the video only 50% of the time (even though it's the same video all the times)
5. Decoding images (especially base64 ones) is sometimes really slow, especially if the image is going in and out of the viewport (again, a image cache problem) ??
@iambibhas
iambibhas / scopes.txt
Last active April 8, 2024 20:37
Sublime Text 2: Snippet scopes
Here is a list of scopes to use in Sublime Text 2 snippets -
ActionScript: source.actionscript.2
AppleScript: source.applescript
ASP: source.asp
Batch FIle: source.dosbatch
C#: source.cs
C++: source.c++
Clojure: source.clojure
CoffeeScript: source.coffee
@vlad-ghita
vlad-ghita / symphony_meet_resources.md
Last active December 1, 2018 16:48
Symphony, meet Resources!

1 Intro

[Symphony][1] is great. Let's make it better.

This article is about the process of building your website's frontend, keeping templates DRY, relating Datasources, Events and other Resources to your Pages, code structure and much more. The following haven arisen, in time, from finding myself repeating the same things over and over again.

I assume you know what [master.xsl][2] is and you are using it. If you don't know, check the [default Symphony workspace][3].

2 It all starts with a requirement

@coolaj86
coolaj86 / how-to-publish-to-npm.md
Last active April 2, 2024 20:18
How to publish packages to NPM

Getting Started with NPM (as a developer)

As easy as 1, 2, 3!

Updated:

  • Aug, 08, 2022 update config docs for npm 8+
  • Jul 27, 2021 add private scopes
  • Jul 22, 2021 add dist tags
  • Jun 20, 2021 update for --access=public
  • Sep 07, 2020 update docs for npm version