jlukic
9 years ago
6 changed files with 20 additions and 108 deletions
Unified View
Diff Options
-
6RELEASE-NOTES.md
-
64tasks/admin/register-repos.js
-
29tasks/admin/release-all.js
-
5tasks/admin/release.js
-
23tasks/collections/admin.js
-
1tasks/config/admin/release.js
@ -1,64 +0,0 @@ |
|||||
/******************************* |
|
||||
Register PM |
|
||||
*******************************/ |
|
||||
|
|
||||
/* |
|
||||
Task to register component repos with Package Managers |
|
||||
* Registers component with bower |
|
||||
* Registers component with NPM |
|
||||
*/ |
|
||||
|
|
||||
var |
|
||||
// node dependencies
|
|
||||
process = require('child_process'), |
|
||||
|
|
||||
// config
|
|
||||
release = require('../config/admin/release'), |
|
||||
|
|
||||
total = release.components.length, |
|
||||
index = -1, |
|
||||
stream, |
|
||||
stepRepo |
|
||||
; |
|
||||
|
|
||||
module.exports = function(callback) { |
|
||||
|
|
||||
console.log('Registering repos with package managers'); |
|
||||
|
|
||||
// Do Git commands synchronously per component, to avoid issues
|
|
||||
stepRepo = function() { |
|
||||
index = index + 1; |
|
||||
if(index >= total) { |
|
||||
return; |
|
||||
} |
|
||||
var |
|
||||
component = release.components[index], |
|
||||
outputDirectory = release.outputRoot + component + '/', |
|
||||
capitalizedComponent = component.charAt(0).toUpperCase() + component.slice(1), |
|
||||
packageName = release.packageRoot + component, |
|
||||
repoName = release.repoRoot + capitalizedComponent, |
|
||||
gitURL = 'https://github.com/' + release.org + '/' + repoName + '.git', |
|
||||
exec = process.exec, |
|
||||
execSettings = {cwd: outputDirectory}, |
|
||||
registerBower = 'bower register ' + packageName + ' ' + gitURL, |
|
||||
updateNPM = 'npm publish' |
|
||||
|
|
||||
; |
|
||||
|
|
||||
/* Register with Bower */ |
|
||||
/* One Time |
|
||||
exec(registerBower, execSettings, function(err, stdout, stderr) { |
|
||||
stepRepo(); |
|
||||
}); |
|
||||
*/ |
|
||||
|
|
||||
/* Register with NPM */ |
|
||||
exec(updateNPM, execSettings, function(err, stdout, stderr) { |
|
||||
console.log(err, stdout, stderr); |
|
||||
stepRepo(); |
|
||||
}); |
|
||||
|
|
||||
}; |
|
||||
stepRepo(); |
|
||||
}; |
|
||||
|
|
@ -1,29 +0,0 @@ |
|||||
/******************************* |
|
||||
Release All |
|
||||
*******************************/ |
|
||||
|
|
||||
/* |
|
||||
This task update all SUI individual component repos with new versions of components |
|
||||
|
|
||||
* Initializes repositories with current versions |
|
||||
* Creates local files at ../components/ with each repo for release |
|
||||
* Commits changes from create components |
|
||||
* Registers new versions with NPM Publish |
|
||||
|
|
||||
*/ |
|
||||
|
|
||||
var |
|
||||
runSequence = require('run-sequence') |
|
||||
; |
|
||||
|
|
||||
/* Release All */ |
|
||||
module.exports = function() { |
|
||||
|
|
||||
runSequence( |
|
||||
'build', // build Semantic
|
|
||||
'init components', // sync with current github version
|
|
||||
'create components', // update each repo
|
|
||||
'update components' // commit changes to github
|
|
||||
); |
|
||||
|
|
||||
}; |
|
Write
Preview
Loading…
Cancel
Save