Skip to content

Instantly share code, notes, and snippets.

View kprav33n's full-sized avatar

Praveen Kumar kprav33n

View GitHub Profile
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE RebindableSyntax #-}
module Parser where
import Prelude (Char, String)
type Parser a = String -> [(a,String)]
# pyenv plugin for Zsh
eval "$(pyenv init - zsh)"
if pyenv commands | command grep -q virtualenv-init; then
eval "$(pyenv virtualenv-init - zsh)"
fi
# fzf.
[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh
export ZPLUG_HOME=/usr/local/opt/zplug
source $ZPLUG_HOME/init.zsh
# Standard completions.
zplug zsh-users/zsh-completions
# Auto suggestion.
zplug zsh-users/zsh-autosuggestions
# Syntax highlighting in shell.

Watching Video Streams that require VLC Plugin on Mac OS

Install VLC plugin from nightly builds

VLC plugin can be installed from VLC nightly builds. Please be advised that this might be unstable for critical use. Please find the most recent build of VLC-webplugin, and download it. Open the downloaded dmg file, and copy VLC Plugin.plugin to the Internet Plug-Ins directory (/Library/Internet Plug-Ins).

Install Firefox ESR

Download the Firefox Extended Support Release 52.9.0 for Mac OS. If you have a newer version of Mozilla Firefox, delete it, and the user configuration data (~/Library/Application Support/Mozilla) using your own discretion. Open the downloaded dmg file, and copy Firefox to the Applications directory. Open Firefox and ensure that the VLC plugin is available to you by going to the URL about:plugins. You should see something like the foll

@kprav33n
kprav33n / minesweeper.go
Created August 1, 2018 06:17
Solution to LeetCode Minesweeper problem
func updateBoard(board [][]byte, click []int) [][]byte {
r, c := click[0], click[1]
if board[r][c] == 'M' {
// 1. If a mine ('M') is revealed, then the game is over - change it to
// 'X'.
board[r][c] = 'X'
return board
} else if board[r][c] == 'E' {
adjSquares := adjacentSquares(board, click)
var numAdjMines byte
@kprav33n
kprav33n / # curl - 2018-09-12_11-05-26.txt
Created September 12, 2018 18:14
curl on "CentOS Linux release 7.2.1511 (Core) " - Homebrew build logs
Homebrew build logs for curl on "CentOS Linux release 7.2.1511 (Core) "
Build date: 2018-09-12 11:05:26
@kprav33n
kprav33n / # hugo - 2018-09-14_03-36-44.txt
Created September 14, 2018 10:37
hugo on "CentOS Linux release 7.2.1511 (Core) " - Homebrew build logs
Homebrew build logs for hugo on "CentOS Linux release 7.2.1511 (Core) "
Build date: 2018-09-14 03:36:44
@kprav33n
kprav33n / VLC.log
Created October 20, 2018 18:49
VLC RTSP Stream Log
$ /Applications/VLC.app/Contents/MacOS/VLC --rtsp-tcp --verbose 4 <stream>
VLC media player 3.0.4 Vetinari (revision 3.0.4-0-gf615db6332)
[00007fa68a40e850] main libvlc debug: VLC media player - 3.0.4 Vetinari
[00007fa68a40e850] main libvlc debug: Copyright © 1996-2018 the VideoLAN team
[00007fa68a40e850] main libvlc debug: revision 3.0.4-0-gf615db6332
[00007fa68a40e850] main libvlc debug: configured with /Users/d-fu/vlc-3.0/extras/package/macosx/../../../configure '--prefix=/Users/d-fu/vlc-3.0/build/vlc_install_dir' '--enable-macosx' '--enable-merge-ffmpeg' '--enable-osx-notifications' '--enable-faad' '--enable-flac' '--enable-theora' '--enable-shout' '--enable-ncurses' '--enable-twolame' '--enable-realrtsp' '--enable-libass' '--enable-macosx-qtkit' '--enable-macosx-avfoundation' '--disable-skins2' '--disable-xcb' '--disable-caca' '--disable-pulse' '--disable-sdl-image' '--disable-vnc' '--build=x86_64-apple-darwin17' '--host=x86_64-apple-darwin17' '--with-macosx-version-min=10.7' '--with-macosx-sdk=/Applica
@kprav33n
kprav33n / VLC.log
Created October 20, 2018 18:59
VLC log for RTSP stream
vsm-dev ❯ /Applications/VLC.app/Contents/MacOS/VLC --rtsp-tcp --verbose 4 'rtsp://vsm.example.org/uid?token=t'
VLC media player 3.0.4 Vetinari (revision 3.0.4-0-gf615db6332)
[00007fa68a40e850] main libvlc debug: VLC media player - 3.0.4 Vetinari
[00007fa68a40e850] main libvlc debug: Copyright © 1996-2018 the VideoLAN team
[00007fa68a40e850] main libvlc debug: revision 3.0.4-0-gf615db6332
[00007fa68a40e850] main libvlc debug: configured with /Users/d-fu/vlc-3.0/extras/package/macosx/../../../configure '--prefix=/Users/d-fu/vlc-3.0/build/vlc_install_dir' '--enable-macosx' '--enable-merge-ffmpeg' '--enable-osx-notifications' '--enable-faad' '--enable-flac' '--enable-theora' '--enable-shout' '--enable-ncurses' '--enable-twolame' '--enable-realrtsp' '--enable-libass' '--enable-macosx-qtkit' '--enable-macosx-avfoundation' '--disable-skins2' '--disable-xcb' '--disable-caca' '--disable-pulse' '--disable-sdl-image' '--disable-vnc' '--build=x86_64-apple-darwin17' '--host=x86_64-apple-darwin17' '--with-macosx-version-m