Skip to content

Instantly share code, notes, and snippets.

🏠
Working from home

Lishi He ikbear

🏠
Working from home
Block or report user

Report or block ikbear

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@ikbear
ikbear / s3-bucket-move
Created Aug 23, 2019 — forked from alanwill/s3-bucket-move
Move an S3 bucket to a different region
View s3-bucket-move
aws s3 sync s3://oldbucket s3://newbucket --source-region us-west-1 --region us-west-2
@ikbear
ikbear / s3-bucket-move
Created Aug 23, 2019 — forked from alanwill/s3-bucket-move
Move an S3 bucket to a different region
View s3-bucket-move
aws s3 sync s3://oldbucket s3://newbucket --source-region us-west-1 --region us-west-2
@ikbear
ikbear / NetScreen.md
Created Dec 5, 2012
NetScreen的往事
View NetScreen.md

下面是陈首席陈临怀发表在微博上的 [NetScreen的往事],我在看的过程中将其拷贝出来,整理成文,方便想看的人一口气看完。微博见:http://weibo.com/huailinchen

[NetScreen的往事]下午要在厦门见邓锋。突然又想起了许多NetScreen的往事。我是一个能写代码的文艺青年。决定在weibo上,来写写过去,算作为逐渐老去的我们的一点纪念。。。

[NetScreen的往事(1)]2001年的9月11日的早晨。我大概7点左右被人叫醒。纽约遭遇攻击!“。在电视上我看着第2架飞机冲入Tower Building,恍惚做梦一般。。。 上午去公司。。。大家都很担心。知道NetScreen的创办人Feng和Yan也在纽约,处理公司上市的事情。大家都很担心他们。我们是兄弟。

[NetScreen的往事(2)]应该是中午的时候传来消息。他们已经跑到亚特兰大去了。在等待转机。。。大家都在等着他们的回来。记得是晚上7点左右,夏天的加州,依然天很亮。我和Shalang(现Juniper Beijing Director)在楼下抽烟。看见Feng和Yan下车了。。。我是个很感情化的人,冲上去拥抱了Feng。

[NetScreen的往事(3)]Yan是个比较严肃的人,而我的工作基本上是他和Yuming[Palo Alto创办人,今年上市,发大了]直接领导。他经常修理我。有点怕他。不敢和他拥抱。Feng很随和,喜欢开玩笑[含黄色段子]。大家都喜欢他。。。

@ikbear
ikbear / sortmap.go
Created Nov 8, 2012
Sort Map(golang)
View sortmap.go
package main
// sort a map's keys in descending order of its values.
import "sort"
type sortedMap struct {
m map[string]int
s []string
}
@ikbear
ikbear / idle.sh
Last active Jul 8, 2019
Docker image entrypoint idle script
View idle.sh
#!/bin/bash
echo "This is a idle script (infinite loop) to keep container running."
echo "Please replace this script."
cleanup ()
{
kill -s SIGTERM $!
exit 0
}
View links.md
View react_samples_list.md
@ikbear
ikbear / README.md
Created Dec 14, 2018 — forked from hofmannsven/README.md
My simply Git Cheatsheet
@ikbear
ikbear / understanding-word-vectors.ipynb
Created Mar 12, 2018 — forked from aparrish/understanding-word-vectors.ipynb
Understanding word vectors: A tutorial for "Reading and Writing Electronic Text," a class I teach at ITP. (Python 2.7) Code examples released under CC0 https://creativecommons.org/choose/zero/, other text released under CC BY 4.0 https://creativecommons.org/licenses/by/4.0/
View understanding-word-vectors.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@ikbear
ikbear / GoConcurrency.md
Created Oct 20, 2017 — forked from rushilgupta/GoConcurrency.md
Concurrency in golang and a mini Load-balancer
View GoConcurrency.md

INTRO

Concurrency is a domain I have wanted to explore for a long time because the locks and the race conditions have always intimidated me. I recall somebody suggesting concurrency patterns in golang because they said "you share the data and not the variables".

Amused by that, I searched for "concurrency in golang" and bumped into this awesome slide by Rob Pike: https://talks.golang.org/2012/waza.slide#1 which does a great job of explaining channels, concurrency patterns and a mini-architecture of load-balancer (also explains the above one-liner).

Let's dig in:

Goroutines

You can’t perform that action at this time.