This file contains hidden or 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
<?php | |
function site_redirect_provision_apache_vhost_config($uri, $data) { | |
$rval[] = ''; | |
$rval[] = '# Redirect all files public path to sites/$uri/files'; | |
$rval[] = 'RewriteEngine On'; | |
$rval[] = "RewriteCond %{REQUEST_URI} !^/sites/$uri/files"; | |
$rval[] = "RewriteRule ^/sites/[^\/]*/files/(.*)$ /sites/$uri/files/$1 [R=301,L]"; | |
$rval[] = ''; |
This file contains hidden or 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
/** | |
* WebCache service. | |
*/ | |
const crypto = require('crypto'); | |
const fs = require('fs'); | |
const mkdirp = require('mkdirp'); | |
const request = require('request'); | |
const urlParser = require('url'); | |
const zlib = require('zlib'); |
This file contains hidden or 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
/** | |
* Task to pull out specific files from bower packages. | |
*/ | |
module.exports = function (grunt) { | |
grunt.config.set('bower', { | |
install: { | |
options: { | |
layout: function(type, component) { | |
return type; | |
}, |
This file contains hidden or 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
module.exports = { | |
shouldRun: true, | |
startBackgroundProcess: function(){ | |
if(this.shouldRun){ | |
console.log('Doing stuff...'); | |
setTimeout(this.startBackgroundProcess, 1000); | |
} else { | |
this.stopBackgroundProcess(); |
This file contains hidden or 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
/* Place model */ | |
module.exports = { | |
attributes: { | |
name: { | |
type: 'string', | |
required: true | |
}, |