Skip to content

Instantly share code, notes, and snippets.


Grégoire Pineau lyrixx

View GitHub Profile
lyrixx /
Last active Feb 21, 2020
Add shared tracks in to slack to a Spotify Playlist
lyrixx /
Last active Mar 17, 2020
Spotify does not handle Media Keys

Debug media keys and Spotify

TL;DR: There is a bug in gnome that have been fixed in 3.3. But you can temporary fix this issue with: pkill gsd-media-keys

Let's Debug

  1. We check logs

lyrixx / .gitignore
Last active Feb 26, 2020
UUID generation in PHP
lyrixx / HardCoreDebugLogger.php
Last active May 31, 2022
Hardcore Debug Logger
View HardCoreDebugLogger.php
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);
lyrixx / run.php
Last active Oct 7, 2021
Updated your templates with the new twig include
View run.php
- "symfony/finder: ~3.0"
- "symfony/console: ~3.0"
use Symfony\Component\Console\Application;
use Symfony\Component\Console\Input\InputArgument;
use Symfony\Component\Console\Input\InputInterface;
chanmix51 /
Last active Apr 2, 2020
Using arrays in Bash

Using arrays in bash

creating an array

$> my_array=(one two three)

accessing/setting elements

$> echo ${my_array}


lyrixx / Queue.php
Last active Mar 15, 2019
PHP async queue (Process (or not))
View Queue.php
class Queue
private $size;
private $onJobStart;
private $isJobRunning;
private $onJobFinish;
private $queued;
View run.php
- "kriswallsmith/buzz: ^0.15.0"
- "symfony/console: ^3.2@dev"
// Find you token on
use Buzz\Message\Response;
qhwa / go_port_forwarding.go
Last active Jul 24, 2022
network port forwarding in go lang
View go_port_forwarding.go
package main
import (
func main() {
ln, err := net.Listen("tcp", ":8080")
mxlje /
Last active Jan 10, 2022
SSL Certificate Commands

These commands are needed every time you want to generate a new certificate signing request to give to an authority in order for them to generate and sign a certificate for you. solves a lot of the pain involved with SSL certs, but sometimes you still need to go the "old school" route. I constantly forget how this stuff works, so I collected the most important commands (and what they do) here for easy copy & paste.

Generate new private key