- changed title to Add Deployment for Earlier Versions
- changed component to gulp
Add Deployment for Earlier Versions
Issue #3
resolved
Add deployment tasks for earlier versions of AE
Comments (4)
-
-
reporter So I followed up on @vaporstack's suggestion of using fs.readdir and fit it into the new gulp architecture.
Anything I missed?
if (os.platform() == 'darwin') { // console.log(getVersions('/Applications/', 'darwin')); build.deploy = getVersions('/Applications/', 'darwin'); util.log('OS: Mac OS X (darwin)'); logVersions(build.deploy); } else { build.deploy = getVersions('C:/Program Files/', 'win32'); util.log('OS: Windows (win32)'); logVersions(build.deploy); }
function logVersions(buildObj) { for (var obj in buildObj) { util.log('Deploying to AE ' + util.colors.magenta(obj)); } }
function getVersions(appdir, system) { var aeVersions = {}; var arch = os.arch(); var apps = fs.readdirSync(appdir); apps.forEach(function (appname) { if (appname.indexOf('After Effects') != -1) { var split = appname.split(' '); var slice = split.slice(3); var version = slice.join(''); var cepdir; if (system == 'darwin') { if (version == 'CC2015' || version == 'CC2014') { cepdir = '/Library/Application Support/Adobe/CEP/extensions/'; } else { cepdir = undefined; } aeVersions[version] = { esdir: appdir + appname + '/Scripts/ScriptUI Panels/', cepdir: cepdir } } else { if (version == 'CC2015' || version == 'CC2014') { if (arch == 'x64') { cepdir = 'C:/Program Files (x86)/Common Files/Adobe/CEP/extensions'; } else { cepdir = 'C:/Program Files/Common Files/Adobe/CEP/extensions'; } } else { cepdir = undefined; } aeVersions[version] = { esdir: appdir + '/Adobe/' + appname + '/Support Files/Scripts/ScriptUI Panels/', cepdir: cepdir } } } }); return aeVersions; }
build.deploy will be:
{ CC: { esdir: '/Applications/Adobe After Effects CC/Scripts/ScriptUI Panels/', cepdir: undefined }, CC2014: { esdir: '/Applications/Adobe After Effects CC 2014/Scripts/ScriptUI Panels/', cepdir: '/Library/Application Support/Adobe/CEP/extensions/' }, CC2015: { esdir: '/Applications/Adobe After Effects CC 2015/Scripts/ScriptUI Panels/', cepdir: '/Library/Application Support/Adobe/CEP/extensions/' }, CS6: { esdir: '/Applications/Adobe After Effects CS6/Scripts/ScriptUI Panels/', cepdir: undefined } }
-
reporter - changed status to resolved
-
- changed milestone to 1.0 Release
- Log in to comment