Skip to content

Instantly share code, notes, and snippets.

View brownman's full-sized avatar

brownman brownman

  • self
  • israel
View GitHub Profile
@brownman
brownman / game_of_life.js
Created April 3, 2012 10:22 — forked from jszmajda/game_of_life.js
Game of Life in Backbone.js
var stepTime = 1;
var col = undefined;
var Cell = Backbone.Model.extend({
x: -1,
y: -1,
alive: false,
nextAlive: false,
initialize: function() {
@brownman
brownman / bash_echo_server
Created November 12, 2013 12:14
Question: How to send a message between 2 terminal windows ? _ Solution 1: a Bash echo server/client _ dependencies: ncat,cowsay
#!/bin/bash -x
work="$1"
port=2000
host='0.0.0.0'
cmd1='cowsay'
if [ "$work" = 'server' ];then

Responsive Top Menu Pure CSS and HTML by Joni

Hope you like this top menu. The goal is to be super minimal in the HTML and the same for the CSS. The CSS is a bit messy but I think you can understand it.

A Pen by brownman on CodePen.

License.

@brownman
brownman / dropbox_voices.sh
Last active January 4, 2016 08:58
please update me guys !
#!/bin/bash
#http://www.cyberciti.biz/faq/linux-unix-formatting-dates-for-display/
dir_dropbox=~/Dropbox
dir_voices=$dir_dropbox/VOICES
if [ ! -d $dir_voices ];then
echo "can't locate your dropbox folder"
fi
action=${1-run}
@brownman
brownman / google-group.sh
Last active August 29, 2015 13:56
google-group.sh - whatsup clone - version_id: 2
#!/bin/bash
#author: ofer shaham
#plugin: gmail-group
#about: whatsup clone
#version: 2
#date: 4.5.2014
#depend: gxmessage libnotify-bin gmail-notify
#help: utilize shared gmail to act like the mobile application - whatsup
#url_gist: https://gist.github.com/brownman/9019632
#check: ps -ef | grep gmail-notify | grep -v grep
@brownman
brownman / ssh_public_key_auto_create_and_upload.sh
Last active August 29, 2015 14:00
ssh + gihub : create and upload Public Key
#!/bin/bash
#depend: xsel pv
intro(){
echo 'Dependencies:'
cat $0 | grep depend | grep -v grep
echo Press any key to continue
read
}
proxy(){
args=( $@ )
@brownman
brownman / dd_progressbar_pv.sh
Last active May 11, 2020 22:01 — forked from rriemann/gist:1406035
dd + progress bar
##########################################
# ofer shaham (c)
# 5-2014
# to: towards more generic usage
# from: a forked gist
##########################################
#dd command + pipe the progress using: pv
#depend_package: dd pv
##########################################
set -o nounset
#!/bin/sh
# Arch Linux Bootstrap Script
#
# See comments below for running
#
# Partition all of main drive
echo "n
p
#!/bin/bash
HOSTNAME="apollo"
USERNAME="paretech"
TIMEZONE="US/Eastern"
LANGUAGE="en_US.UTF-8"
DRIVE=/dev/sda
MOUNT_PATH=/mnt
USERSHELL=/bin/bash
@brownman
brownman / gist:d2c2905fb24b8591a7cc
Last active August 29, 2015 14:02 — forked from cloudsben/gist:4490135
download_entire_website.sh
# -p parameter tells wget to include all files, including images.
# -e robots=off you don't want wget to obey by the robots.txt file
# -U mozilla as your browsers identity.
# --random-wait to let wget chose a random number of seconds to wait, avoid get into black list.
# Other Useful wget Parameters:
# --limit-rate=20k limits the rate at which it downloads files.
# -b continues wget after logging out.
# -o $HOME/wget_log.txt logs the output
wget --random-wait -r -p -e robots=off -U mozilla http://www.example.com