Skip to content

Instantly share code, notes, and snippets.

View cben's full-sized avatar

Beni Cherniavsky-Paskin cben

View GitHub Profile
import {run} from '@cycle/run';
import {makeCanvasDriver, rect, text} from 'cycle-canvas';
import { makeKeyboardDriver } from 'cycle-keyboard'
import onionify from 'cycle-onionify';
import {makeCollection} from 'cycle-onionify';
import isolate from '@cycle/isolate'
import xs from 'xstream'
import fromEvent from 'xstream/extra/fromEvent'
@Ladas
Ladas / memusg
Created July 21, 2017 12:02
refresh quick perf test, run as ./memusg bundle exec rails r qe_ocp_refresh_manager_first_refresh.rb <ems_name>, grep evm.log for :save_inventory to get a time
#!/usr/bin/env bash
# memusg -- Measure memory usage of processes
# Usage: memusg COMMAND [ARGS]...
#
# Author: Jaeho Shin <[email protected]>
# Created: 2010-08-16
############################################################################
# Copyright 2010 Jaeho Shin. #
# #
# Licensed under the Apache License, Version 2.0 (the "License"); #
@vidarh
vidarh / README.md
Last active July 9, 2017 16:25
Stupid / simple JSON command line processing with Ruby

Based on an example for Elvish.

From comment posted to HN:

I love the structured pipes, but as mentioned in another discussion, replacing the shell is a big leap for a lot of people. And you can get quite far without it with tools like "jq". And when I saw this, I just had to tinker a bit to see what I could do with Ruby, based on the example on the homepage:

$ curl -s https://api.github.com/repos/elves/elvish/issues | jr 'each{|issue| puts "#{issue["number"]}: #{issue["title"]}"} ' | head -n 11

Or (I expect pitchforks when you see the implementation for this):

@blomquisg
blomquisg / review-prs.sh
Last active June 27, 2018 08:42
Script to find Github PRs to review in various repos.
#!/bin/bash
# Open a series of web browsers with the list of PRs slated to review in various Github repositories.
# See _main function at the end.
CLIENT_KEY=
CLIENT_SECRET=
function get_command()
{
@mshkrebtan
mshkrebtan / webex-ubuntu.md
Last active October 28, 2022 15:23
Run Cisco Webex on 64-bit Ubuntu 16.04

Run Cisco Webex on 64-bit Ubuntu 16.04

With Audio and Screen Sharing Enabled

Enable support for 32-bit executables

Add the i386 architecture to the list of dpkg architectures :

sudo dpkg --add-architecture i386
@egmontkob
egmontkob / Hyperlinks_in_Terminal_Emulators.md
Last active August 7, 2025 12:20
Hyperlinks in Terminal Emulators
@NickLaMuro
NickLaMuro / hawkular-metrics-admin-cluster-role.json
Last active April 27, 2017 08:15
Minishift addon for management with ManageIQ
{
"apiVersion": "v1",
"kind": "ClusterRole",
"metadata": {
"name": "hawkular-metrics-admin"
},
"rules": [
{
"apiGroups": [""],
"resources": ["hawkular-metrics","hawkular-alerts"],

The Story of NPM and Yarn

In the beginning there was NPM, and for a time it was good. Packages went forth and multiplied. The New Gods proclaimed the great demon Dependency Management had been slain. But The Old Gods knew better, for they had seen much and knew that the demon can never be killed, only held at bay.

The Old Gods were ignored. In the folly of a young age grew an abundance of packages and with them grew the scourge of dependency. In the depths beneath the earth, in a place beyond memory, the great demon stirred.

The first sign something was wrong was non-deterministic package version mismatches. “This is fine!” The New Gods declared. “A temporary setback, nothing more! We can fix it.” And so they introduced shrinkwrap, a lamp to combat the growing darkness.

But it proved to be too little, too late, and dusk continued to fall. The New Gods suffered their first major defeat at the [Battle of Left-pad](https://www.theregister.co.uk/2016/03/23/npm_left_

@j-jith
j-jith / miui-fastboot-howto.rst
Last active June 16, 2025 05:00
How to flash MIUI Fastboot ROM from Linux

How to flash MIUI Fastboot ROM from Linux

@postpostscript
postpostscript / replify
Last active November 7, 2024 02:47
replify - Create a REPL for any command
#!/bin/sh
command="${*}"
printf "Initialized REPL for `%s`\n" "$command"
printf "%s> " "$command"
read -r input
while [ "$input" != "" ];
do
eval "$command $input"
printf "%s> " "$command"