Question re: should this be rack's job
# config.ru
run ->(env) {
[ 200, { 'Content-Type' => 'text/html', }, [Rack::Request.new(env).params.inspect] ]
}| //<editor-fold desc="Node Requires, gulp, etc"> | |
| var gulp = require('gulp'), | |
| autoprefixer = require('gulp-autoprefixer'), | |
| clean = require('gulp-clean'), | |
| concat = require('gulp-concat'), | |
| csso = require('gulp-csso'), | |
| debug = require('gulp-debug'), | |
| footer = require('gulp-footer'), | |
| gutil = require('gulp-util'), | |
| gzip = require('gulp-gzip'), |
| # Call scopes directly from your URL params: | |
| # | |
| # @products = Product.filter(params.slice(:status, :location, :starts_with)) | |
| module Filterable | |
| extend ActiveSupport::Concern | |
| module ClassMethods | |
| # Call the class methods with names based on the keys in <tt>filtering_params</tt> | |
| # with their associated values. For example, "{ status: 'delayed' }" would call |
| packages: | |
| yum: | |
| gcc-c++: [] | |
| make: [] | |
| sources: | |
| /home/ec2-user: http://download.redis.io/releases/redis-2.8.4.tar.gz | |
| commands: | |
| redis_build: | |
| command: make | |
| cwd: /home/ec2-user/redis-2.8.4 |
| // Wrapping of the example found on https://gist.github.com/alunny/1904992 | |
| // Jordi Moraleda | |
| // This example works on org.apache.cordova.file version 1.1.0 and 1.2.0 | |
| // | |
| // If you are using version 1.3.0, check out the file below | |
| // https://gist.github.com/jmoraleda/78551f439578f7c132c8#file-fswrapper-v1-3-js | |
| function FSWrapper(options, callback) { | |
| var self = this; |
Question re: should this be rack's job
# config.ru
run ->(env) {
[ 200, { 'Content-Type' => 'text/html', }, [Rack::Request.new(env).params.inspect] ]
}| # less to scss based on http://stackoverflow.com/a/19167099/2363935 | |
| namespace :convert do | |
| task :less_to_scss do | |
| source_glob = "assets/less/*.less" | |
| dest_dir = "converted" | |
| rm_r dest_dir rescue nil | |
| mkdir_p(dest_dir) |
| var gulp = require('gulp'); | |
| var connect = require('gulp-connect'); | |
| var modRewrite = require('connect-modrewrite'); | |
| var runSequence = require('run-sequence'); | |
| var shell = require('gulp-shell'); | |
| //proxy all requests to /api to localhost:3000 for rails api | |
| gulp.task('connect', function(){ | |
| connect.server({ | |
| root: './app', |
| def show | |
| if stale?(@model, public: true) | |
| respond_to do |format| | |
| format.json do | |
| full_structure_json = Rails.cache.fetch("#{@model.cache_key}") do | |
| MyCustomSerializer.new(@model).to_json | |
| end | |
| render json: full_structure_json | |
| end |
| web: | |
| build: . | |
| volumes: | |
| - .:/opt/myapp | |
| ports: | |
| - '3000:3000' | |
| links: | |
| - db | |
| - redis | |
| - selenium |