Skip to content

Instantly share code, notes, and snippets.

View rien333's full-sized avatar

Rijnder Wever rien333

View GitHub Profile
@rien333
rien333 / observer.m
Created January 22, 2018 23:25
Command-line app that tells a bitbar chunkwm plugin to refresh when the user changes spaces
#import <Cocoa/Cocoa.h>
@interface SpaceChangeNotifier : NSObject
- (void) registerNotifier;
- (void)spaceChanged:(NSNotification *)aNotification;
@end
@implementation SpaceChangeNotifier
- (id) init
defaults write -g NSAutomaticWindowAnimationsEnabled -bool false
defaults write -g NSScrollAnimationEnabled -bool false
defaults write -g NSWindowResizeTime -float 0.001
defaults write -g QLPanelAnimationDuration -float 0
defaults write -g NSScrollViewRubberbanding -bool false
defaults write -g NSDocumentRevisionsWindowTransformAnimation -bool false
defaults write -g NSToolbarFullScreenAnimationDuration -float 0
defaults write -g NSBrowserColumnAnimationSpeedMultiplier -float 0
defaults write com.apple.dock autohide-time-modifier -float 0
defaults write com.apple.dock autohide-delay -float 0
@rien333
rien333 / live-ascii-andriod.py
Last active December 6, 2017 15:55
ascii live art on an andriod phone
import numpy as np
from scipy.misc import imresize
from PIL import Image
from os import system
from time import sleep
# Method to convert images(/image buffers?) to ascii art
# Change this to either use a shared library (.so) file or the python img2txt module
# stolen from img2txt.generate_grayscale_for_image
def img2ascii(pixels, height, width):
youtube-dl --verbose --cookies cookies.txt 'https://www.twitch.tv/videos/176220025'
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: [u'--verbose', u'--cookies', u'cookies.txt', u'https://www.twitch.tv/videos/176220025']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2017.09.15
[debug] Python version 2.7.10 - Darwin-16.7.0-x86_64-i386-64bit
[debug] exe versions: avconv 12.1, avprobe 12.1, ffmpeg 3.3.4, ffprobe 3.3.4, rtmpdump 2.4
[debug] Proxy map: {}
@rien333
rien333 / # picoc - 2017-08-13_20-08-25.txt
Created August 13, 2017 18:10
picoc on macOS 10.12.6 - Homebrew build logs
Homebrew build logs for picoc on macOS 10.12.6
Build date: 2017-08-13 20:08:25
@rien333
rien333 / # mplayer - 2017-06-23_13-43-41.txt
Created June 23, 2017 11:48
mplayer on macOS 10.12.5 - Homebrew build logs
Homebrew build logs for mplayer on macOS 10.12.5
Build date: 2017-06-23 13:43:41
$ brew config
-----------------------
HOMEBREW_VERSION: 1.2.3
ORIGIN: https://github.com/Homebrew/brew.git
HEAD: ed9942fbd1ec4243f0a92ab8f9b2411c8b1fb091
Last commit: 11 days ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: 8fe0247635d6720deee9dfa9d0c72be36a7c6a4a
Core tap last commit: 2 hours ago
HOMEBREW_PREFIX: /usr/local