This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 0b040f756dae5d9a1f7306bdea386cb848447a1b Mon Sep 17 00:00:00 2001 | |
From: Amitava Shee <[email protected]> | |
Date: Mon, 14 Feb 2011 14:47:32 -0500 | |
Subject: [PATCH] Permission denied fix | |
--- | |
lib/mirah_task.rb | 2 +- | |
1 files changed, 1 insertions(+), 1 deletions(-) | |
diff --git a/lib/mirah_task.rb b/lib/mirah_task.rb |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# copy and paste the command below at the shell to reset mysql password without being recorded in shell history | |
read -s PASS && mysqladmin -u root -p password $PASS | |
# another approach - read silently and export | |
read -s PASS && export PASS | |
mysqladmin -uroot -p password $PASS |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
read -s PASS && export PASS | |
mysql -uroot -p -e "GRANT SHOW DATABASES, SELECT, LOCK TABLES, RELOAD ON *.* to backup@localhost IDENTIFIED BY '$PASS';FLUSH PRIVILEGES;" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export COPY_EXTENDED_ATTRIBUTES_DISABLE=true | |
export COPYFILE_DISABLE=true | |
tar cvzf lmslc-v1.0.011.tgz --exclude=".git" --exclude=".DS_Store" lc |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wget --mirror -p --convert-links -P ./output-dir url |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export ANT_OPTS="-Xms1024M -Xmx2048M -XX:MaxPermSize=512m" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
####################### | |
# A script by Salvatore Sanfilippo that I came upon in Twitter | |
##################### | |
ramfs_size_mb=1024 | |
mount_point=~/volatile | |
ramfs_size_sectors=$((${ramfs_size_mb}*1024*1024/512)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// From Runar Oli's tweet | |
def enumResultSet[E,A](rs: ResultSet, iter: IterV[E, A], get: ResultSet => IO[E]): IO[IterV[E, A]] = { | |
def loop(i: IterV[E, A]): IO[IterV[E, A]] = | |
i.fold(done = (_, _) => i.pure[IO], | |
cont = k => next(rs) >>= (hasMore => | |
if (!hasMore) i.pure[IO] | |
else get(rs) >>= (t => loop(k(El(t)))))) | |
loop(iter) | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
amitava@bonjovi:~$ sudo virsh | |
Welcome to virsh, the virtualization interactive terminal. | |
Type: 'help' for help with commands | |
'quit' to quit | |
virsh # start latticegrid-demo | |
Domain latticegrid-demo started | |
virsh # list |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
menu | |
Status #scalazX | |
[Scalaz http://code.google.com/p/scalaz Git source http://github.com/scalaz/scalaz | http://vimeo.com/10482466] | |
[15:29] == amitava [8dd61105@gateway/web/freenode/ip.141.214.17.5] has joined #scalaz | |
[15:30] <amitava> hi all - i am trying to understand the following code from applicative | |
[15:30] <amitava> applicative[({type λ[α] = State[A, α]})#λ](StatePure, StateApply) | |
[15:31] <amitava> what does the construct {type λ[α] = State[A, α]})#λ do? | |
[15:33] == alex_boisvert [[email protected]] has quit [Ping timeout: 252 seconds] | |
[15:39] <larsrh> amitava: it's a partial type application | |
[15:40] <larsrh> imagine this syntax: α => State[A, α] |