Skip to content

Instantly share code, notes, and snippets.

View bzf's full-sized avatar

André Ligné bzf

View GitHub Profile
@bzf
bzf / flake.nix
Created August 25, 2022 06:16
Building Ruby with flake.nix
{
description = "my very own ruby";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs";
};
outputs = { self, nixpkgs }:
let
pkgs = import nixpkgs {
import Controller from '@ember/controller';
export default class ApplicationController extends Controller {
appName = 'Ember Twiddle';
}
@bzf
bzf / keybase.md
Created September 14, 2019 09:29

Keybase proof

I hereby claim:

  • I am bzf on github.
  • I am andreligne (https://keybase.io/andreligne) on keybase.
  • I have a public key ASCFBQot9gdAZOnXTj509IJKD99Fv2h4YjEnKFv1S9-Bhgo

To claim this, I am signing this object:

@bzf
bzf / controllers.application.js
Last active October 4, 2017 16:08
ember-power-select w/ ember-concurrency
import Ember from 'ember';
import { task, timeout } from 'ember-concurrency';
const { get, set } = Ember;
export default Ember.Controller.extend({
appName: 'Ember Twiddle',
query: 'ember-power-select',
@bzf
bzf / count_history
Last active February 3, 2017 09:12
#!/usr/bin/ruby
content_lines = File.readlines "#{Dir.home}/.zsh_history"
content_lines.map! do |line|
line.split.first
end
counts = Hash.new 0
content_lines.each do |cmd|
@bzf
bzf / post-checkout
Last active August 29, 2015 14:24
Run updates when checking out a branch
#!/bin/sh
#
# You can have git always initialize local repositories with some default
# hook files. This can be done by setting the init.templatedir in your
# .gitconfig. Then create the folder `hooks/` and put you hooks there.
#
# Put this file in `.git/hooks/post-checkout`, set is as an executeable and it will
# run the given command if the given file has changed between the commits.
# Format: run_update <filename> <command(s)>
### Keybase proof
I hereby claim:
* I am bzf on github.
* I am bzf (https://keybase.io/bzf) on keybase.
* I have a public key whose fingerprint is B730 954C 1D2B CB2E D279 1A31 6425 4651 2A2E 6CB4
To claim this, I am signing this object:
@bzf
bzf / gist:d65c2f2cbe0676efb222
Created September 18, 2014 11:55
make_unique<T>
namespace std
{
template<class T>
std::unique_ptr<T> make_unique(T &&x)
{
return std::unique_ptr<T>(new T(std::forward<T>(x)));
};
};
@bzf
bzf / gist:8445560
Created January 15, 2014 21:56
faces
༼ つ ◕_◕ ༽つ GIFF DUNDUNDUN
ヽ༼ຈل͜ຈ༽ノ raise your pgg ヽ༼ຈل͜ຈ༽ノ
༼ ᕤ ◕_◕ ༽ᕤ
ლ(ಠ益ಠლ) BUT TO WHAT END?!
ლ(ಠ益ಠლ) BUT AT WAT COST?!
@bzf
bzf / SuchQ.h
Created January 15, 2014 21:33
Just testing out some networking in C++ using boost.asio
#ifndef SUCH_Q_
#define SUCH_Q_
#include <iostream>
#include <queue>
#include <semaphore.h>
#define SEMA "ASDF"
template <class T>