This file contains 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
// Hello. I'm learning. Thank you for sharing your insights. | |
var sUtil = require('sUtils.js'); | |
var obj = { | |
a:[1,2], | |
b:[3,4], | |
} | |
Object.keys(obj).forEach(function(key) { | |
if (Array.isArray(obj[key])) { |
This file contains 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
zipstream = require "zipstream" | |
fs = require "fs" | |
async = require "async" | |
class StreamingResponse | |
filename: "" | |
files: [] | |
streaming: true | |
### |
This file contains 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
script(id='pageTpl', type='text/html') | |
| <div class="page"> | |
| <div class="head"><%=title%> - <%=path%></div> | |
| <div class="body"> | |
| <ul> | |
| <% _(actions).each(function(action) { %> | |
| <li> | |
| <%=action.name%> - <%=Helpers.df(action.time)%> | |
| <% if (action.ext) { %> | |
| <i class="pop icon-info-sign" data-content="<%=_.template($('#extTpl').html(), action)%>" data-original-title="Extra Information"></i> |
This file contains 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
# Ways to execute a shell script in Ruby | |
# Example Script - Joseph Pecoraro | |
cmd = "echo 'hi'" # Sample string that can be used | |
# 1. Kernel#` - commonly called backticks - `cmd` | |
# This is like many other languages, including bash, PHP, and Perl | |
# Returns the result of the shell command | |
# Docs: http://ruby-doc.org/core/classes/Kernel.html#M001111 |