Skip to content

Instantly share code, notes, and snippets.

swagger: '2.0'
info:
description: |
TechHub API
[http://swagger.io](http://swagger.io) or on
[irc.freenode.net, #swagger](http://swagger.io/irc/).
version: 1.0.0
title: TechHub
termsOfService: http://swagger.io/terms/
contact:
apiVersion: v1
kind: Service
metadata:
name: athenapdfgenerator5
namespace: default
spec:
externalTrafficPolicy: Cluster
ports:
- name: http
port: 80
{
"ProjectDetails": {
"Client": "Tesla Inc",
"PDSMarket": "Austin, TX"
},
"ProgramSummary": {
"NetProgramSqFt": 14863,
"CirculationMultipliedSqFt": 8918,
"UsableSqFt": 23781,
"BuildingGrossUpSqFt": 4281,
@patelsan
patelsan / style.css
Created October 18, 2017 19:14
VSCodeCustomization
.type.storage,.type.storage.declaration, .storage.class.modifier {
font-family: 'flottflott';
font-size: 1.7em;
}
.type.storage.arrow.function {
font-family: 'Fira Code'
}
.decorator.name, .decorator.punctuation:not(.block), .import.keyword {
class Singleton
# We can make private variables!
instance = null
# Static singleton retriever/loader
@get: ->
if not @instance?
instance = new @
instance.init()

#How you get Sail.js running on Openshift#

This instruction is tested with:

  • Sails.js v0.9.16
  • Node.js 0.10 on Openshift ( 05 May 2014)

###1) package.json

If you use the package.json build by sails new Projectname than you have to add a few fields for openshift – so the server can start you app automatically. Sails uses Grunt to build minify css/js and so on. Openshift dont have grunt installed so you have to add this also.

// make a module in node_modules named 'my-validation-utils'. create a index.js file there. and put the following content there:
var user = {
email:{
required:'Email Required',
email:'Should be an email'
},
name:{
required:'name required'
}
###
Detect browser name, version and OS
@ref: http://www.quirksmode.org/js/detect.html
###
class Detector
constructor: ->
@browser = @searchString(Detector.dataBrowser) or "An unknown browser"
@version = @searchVersion(navigator.userAgent) or @searchVersion(navigator.appVersion) or "An unknown browser"
@OS = @searchString(Detector.dataOS) or "An unknown OS"
Writable = require('stream').Writable
AWS = require('aws-sdk')
S3Uploader = (options = {})->
AWS.config.loadFromPath('./config/s3.json') #ToDo: ideally this should be done only once
uploader__ = Writable({objectMode: true})
uploader__.write = (__newFile, encoding, done)->
console.log __newFile.filename
s3 = new AWS.S3()