Skip to content

Instantly share code, notes, and snippets.

@khris
khris / gist:f05dc3d3275ae5e8c7ae
Created October 8, 2014 09:57
Set a field name in a MongoDB document with dollar sign($)
db.application.update(
{field1: 'value1'},
{$set: {'subdoc.$field_name_with_dollar_sign': 'value2'}}
)

Keybase proof

I hereby claim:

  • I am khris on github.
  • I am khris (https://keybase.io/khris) on keybase.
  • I have a public key whose fingerprint is BE0A 44C6 B37C 3B23 A891 785E E006 1B23 A3B1 BD0F

To claim this, I am signing this object:

@khris
khris / kaist_chan.html
Last active August 29, 2015 14:10
넙죽이 머리 그리기 http://jsfiddle.net/khris/0goy12pL/
<!DOCTYPE html>
<html>
<head lang="ko">
<meta charset="UTF-8">
<title>넙죽이</title>
<script type="text/javascript">
function draw() {
var canvas = document.getElementById('kaist_chan');
var ctx = canvas.getContext('2d');
ctx.fillStyle = 'rgba(22, 160, 220, 1)';