Skip to content

Instantly share code, notes, and snippets.

@clonn
clonn / app.js
Last active August 29, 2015 14:00
app = angular.module("myApp", ["service.create"])
@clonn
clonn / index.ejs
Created April 19, 2014 04:36
sails.js simple chat gist, can check full status , https://github.com/clonn/sails-talk-demo
<div class="container" ng-app ng-controller="rootController">
<form action="/comment/create" method="POST" id="message-form">
<div class="form-group">
<input type="text" id="messge" ng-model="message" name="comments" placeholder="input comments ..." >
</div>
<button type="submit" class="btn btn-success">comment</button>
</form>
<div class="message">
@clonn
clonn / server.js
Created April 19, 2014 04:14
simple node.js server
var http = require("http");
var port = 1337;
http.createServer(function (req, res) {
res.end("OK");
}).listen(port);
console.log("Start server port is " + port );
@clonn
clonn / node_ruby_install.sh
Last active December 5, 2023 04:11
node.js installation and ruby installation, shell.
#!/bin/sh
#need to install redis and mysql
# MacOS env
brew install redis
brew install mysql
brew install zmq
cd ~/
@clonn
clonn / jsoup web parse android intelliJ.md
Last active August 29, 2015 13:57
android parse web page - jsoup. use in intelliJ IDE, 用來抓網頁使用,主要處理 query URL, DOM parsing.

#android parse web page - jsoup. use in intelliJ IDE

now you can parse web page like jQUery, "jsoup".

##install jsoup,

Download jsoup jar, and import to your project. save jsoup.jar in libs folder in your project.

@clonn
clonn / Failure [INSTALL_FAILED_OLDER_SDK].md
Last active August 29, 2015 13:57
intellij deploy to genymotion got error, Failure [INSTALL_FAILED_OLDER_SDK], 當執行發生錯誤的時候,解決方法

#when genymotion runs error.

After a lots setting, we can start intellij with genymotion.

if you face executed ERROR, message like this,

Failure [INSTALL_FAILED_OLDER_SDK]

##make sure you ADV version.

@clonn
clonn / Setting android in intelliJ IDE.md
Last active August 29, 2015 13:57
setting android environment in IntelliJ IDE, 設定 intelliJ IDE 的方法,以及實際遇到的問題, include android sdk, jdk setting.
@clonn
clonn / User.js
Last active December 31, 2015 09:58
talk for user login, demo for ncue
// Path: /api/models/user.js
module.exports = {
attributes: {
/* e.g.
nickname: 'string'
*/
username: "string",
@clonn
clonn / npm_plugin_install.sh
Last active December 23, 2015 06:09
node.js command line usage cli tool, one line install * express * grunt, grunt-init * bower * coffee-script
npm install -g express grunt-init grunt bower coffee-script js2coffee
@clonn
clonn / nvm_install.sh
Last active May 29, 2019 04:40
node install flow by nvm
# linux or mac
cd ~/
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.34.0/install.sh | bash
cat ~/.nvm/nvm.sh >> ~/.bashrc
source ~/.nvm/nvm.sh
nvm install v10.15.3
nvm use v10.15.3
nvm alias default v10.15.3