Return-Path: X-Original-To: apmail-flex-commits-archive@www.apache.org Delivered-To: apmail-flex-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id DF66418A4E for ; Sun, 13 Mar 2016 08:45:21 +0000 (UTC) Received: (qmail 91521 invoked by uid 500); 13 Mar 2016 08:45:16 -0000 Delivered-To: apmail-flex-commits-archive@flex.apache.org Received: (qmail 91379 invoked by uid 500); 13 Mar 2016 08:45:16 -0000 Mailing-List: contact commits-help@flex.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@flex.apache.org Delivered-To: mailing list commits@flex.apache.org Received: (qmail 91366 invoked by uid 99); 13 Mar 2016 08:45:16 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 13 Mar 2016 08:45:16 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 6E3DFDFFAB; Sun, 13 Mar 2016 08:45:16 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: bigosmallm@apache.org To: commits@flex.apache.org Date: Sun, 13 Mar 2016 08:45:17 -0000 Message-Id: <3bd724d4d27a42889bc436f0b58c893e@git.apache.org> In-Reply-To: <1aae773fa0954520bc4bba19058b9459@git.apache.org> References: <1aae773fa0954520bc4bba19058b9459@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [02/16] git commit: [flex-utilities] [refs/heads/develop] - Split download responsibilities to individual classes; Make individual classes extend EventEmitter; Make downloads sequential; Refactoring. Split download responsibilities to individual classes; Make individual classes extend EventEmitter; Make downloads sequential; Refactoring. Project: http://git-wip-us.apache.org/repos/asf/flex-utilities/repo Commit: http://git-wip-us.apache.org/repos/asf/flex-utilities/commit/490f9109 Tree: http://git-wip-us.apache.org/repos/asf/flex-utilities/tree/490f9109 Diff: http://git-wip-us.apache.org/repos/asf/flex-utilities/diff/490f9109 Branch: refs/heads/develop Commit: 490f91091d16ae9db8f9b2ab9d1f81d7c8fae654 Parents: f6c7e2a Author: OmPrakash Muppirala Authored: Sun Nov 29 01:57:04 2015 -0800 Committer: OmPrakash Muppirala Committed: Sun Mar 13 00:44:02 2016 -0800 ---------------------------------------------------------------------- npm-flexjs/dependencies/AdobeAIR.js | 79 +++++++++++++++++++ npm-flexjs/dependencies/ApacheFalcon.js | 55 ++++++++++++++ npm-flexjs/dependencies/ApacheFlexJS.js | 54 +++++++++++++ npm-flexjs/dependencies/Constants.js | 26 +++++++ npm-flexjs/dependencies/FlashPlayerGlobal.js | 86 +++++++++++++++++++++ npm-flexjs/dependencies/SWFObject.js | 49 ++++++++++++ npm-flexjs/download_dependencies.js | 79 +++++++++++++++++++ npm-flexjs/package.json | 3 +- npm-flexjs/prepublish.js | 93 ----------------------- 9 files changed, 430 insertions(+), 94 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/flex-utilities/blob/490f9109/npm-flexjs/dependencies/AdobeAIR.js ---------------------------------------------------------------------- diff --git a/npm-flexjs/dependencies/AdobeAIR.js b/npm-flexjs/dependencies/AdobeAIR.js new file mode 100644 index 0000000..0a023d4 --- /dev/null +++ b/npm-flexjs/dependencies/AdobeAIR.js @@ -0,0 +1,79 @@ +/* + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + + +var request = require('request'); +var fs = require('fs'); +var events = require('events'); +var prompt = require('prompt'); + +var constants = require('../dependencies/Constants'); + +var AdobeAIR = module.exports = Object.create(events.EventEmitter.prototype); + +//Adobe AIR +var AdobeAIRURL = 'http://airdownload.adobe.com/air/win/download/19.0/'; +var fileNameAdobeAIR = 'AdobeAIRSDK.zip'; +var adobeAirPromptText = "\ +Apache Flex SDK uses the Adobe AIR SDK to build Adobe AIR applications.\n\ +The Adobe AIR SDK is subject to and governed by the\n\ +Adobe AIR SDK License Agreement specified here:\n\ +http://www.adobe.com/products/air/sdk-eula.html.\n\ + This license is not compatible with the Apache v2 license.\n\ +Do you want to download and install the Adobe AIR SDK? (y/n)"; + +AdobeAIR.promptForAdobeAIR = function() +{ + var schema = { + properties: { + accept: { + description: adobeAirPromptText.magenta, + pattern: /^[YNyn\s]{1}$/, + message: 'Please respond with either y or n'.red, + required: true + } + } + }; + prompt.start(); + prompt.get(schema, function (err, result) { + console.log(' accept?: ' + result.accept); + if(result.accept.toLowerCase() == 'y') + { + AdobeAIR.downloadAdobeAIR(); + } + }); +}; + +AdobeAIR.downloadAdobeAIR = function() +{ + console.log('Downloading Adobe AIR SDK'); + request + .get(AdobeAIRURL + fileNameAdobeAIR) + .pipe(fs.createWriteStream(constants.DOWNLOADS_FOLDER + '//' + fileNameAdobeAIR) + .on('finish', function(){ + console.log('Adobe AIR download complete'); + AdobeAIR.emit('complete'); + }) + ); +}; + +AdobeAIR.install = function() +{ + AdobeAIR.promptForAdobeAIR(); +}; \ No newline at end of file http://git-wip-us.apache.org/repos/asf/flex-utilities/blob/490f9109/npm-flexjs/dependencies/ApacheFalcon.js ---------------------------------------------------------------------- diff --git a/npm-flexjs/dependencies/ApacheFalcon.js b/npm-flexjs/dependencies/ApacheFalcon.js new file mode 100644 index 0000000..1f24bb4 --- /dev/null +++ b/npm-flexjs/dependencies/ApacheFalcon.js @@ -0,0 +1,55 @@ +/* + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + + +var request = require('request'); +var fs = require('fs'); +var events = require('events'); + +var constants = require('../dependencies/Constants'); + +var ApacheFalcon = module.exports = Object.create(events.EventEmitter.prototype); + +//Falcon +var pathToFalconBinary = 'flex/falcon/0.5.0/binaries/'; +var fileNameFalconBinary = 'apache-flex-falconjx-0.5.0-bin.zip'; + +ApacheFalcon.handleFalconMirrorsResponse = function (error, response, body) +{ + if (!error && response.statusCode == 200) + { + var mirrors = JSON.parse(body); + var falconPreferredDownloadURL = mirrors.preferred + pathToFalconBinary + fileNameFalconBinary; + console.log('Downloading Apache Falcon'); + request + .get(falconPreferredDownloadURL) + .pipe(fs.createWriteStream('downloads//' + fileNameFalconBinary) + .on('finish', function(){ + console.log('Apache Falcon download complete'); + ApacheFalcon.emit('complete'); + }) + ); + } + +}; + +ApacheFalcon.install = function() +{ + request(constants.APACHE_MIRROR_RESOLVER_URL + pathToFalconBinary + fileNameFalconBinary + '?' + constants.REQUEST_JSON_PARAM, ApacheFalcon.handleFalconMirrorsResponse); +}; \ No newline at end of file http://git-wip-us.apache.org/repos/asf/flex-utilities/blob/490f9109/npm-flexjs/dependencies/ApacheFlexJS.js ---------------------------------------------------------------------- diff --git a/npm-flexjs/dependencies/ApacheFlexJS.js b/npm-flexjs/dependencies/ApacheFlexJS.js new file mode 100644 index 0000000..5a42bbd --- /dev/null +++ b/npm-flexjs/dependencies/ApacheFlexJS.js @@ -0,0 +1,54 @@ +/* + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + + +var request = require('request'); +var fs = require('fs'); +var events = require('events'); + +var constants = require('../dependencies/Constants'); + +var ApacheFlexJS = module.exports = Object.create(events.EventEmitter.prototype); + +//FlexJS +var pathToFlexJSBinary = 'flex/flexjs/0.5.0/binaries/'; +var fileNameFlexJSBinary = 'apache-flex-flexjs-0.5.0-bin.zip'; + +ApacheFlexJS.handleFlexJSMirrorsResponse = function (error, response, body) +{ + if (!error && response.statusCode == 200) + { + var mirrors = JSON.parse(body); + var flexJSPreferredDownloadURL = mirrors.preferred + pathToFlexJSBinary + fileNameFlexJSBinary; + console.log('Downloading Apache FlexJS'); + request + .get(flexJSPreferredDownloadURL) + .pipe(fs.createWriteStream(constants.DOWNLOADS_FOLDER + '//' + fileNameFlexJSBinary) + .on('finish', function(){ + console.log('Apache FlexJS download complete'); + ApacheFlexJS.emit('complete'); + }) + ); + } +}; + +ApacheFlexJS.install = function() +{ + request(constants.APACHE_MIRROR_RESOLVER_URL + pathToFlexJSBinary + fileNameFlexJSBinary + '?' + constants.REQUEST_JSON_PARAM, ApacheFlexJS.handleFlexJSMirrorsResponse); +}; \ No newline at end of file http://git-wip-us.apache.org/repos/asf/flex-utilities/blob/490f9109/npm-flexjs/dependencies/Constants.js ---------------------------------------------------------------------- diff --git a/npm-flexjs/dependencies/Constants.js b/npm-flexjs/dependencies/Constants.js new file mode 100644 index 0000000..363e688 --- /dev/null +++ b/npm-flexjs/dependencies/Constants.js @@ -0,0 +1,26 @@ +/* + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + +//Define all constants here +module.exports = +{ + APACHE_MIRROR_RESOLVER_URL : 'http://www.apache.org/dyn/mirrors/mirrors.cgi/', + REQUEST_JSON_PARAM : 'asjson=true', + DOWNLOADS_FOLDER : 'downloads' +}; \ No newline at end of file http://git-wip-us.apache.org/repos/asf/flex-utilities/blob/490f9109/npm-flexjs/dependencies/FlashPlayerGlobal.js ---------------------------------------------------------------------- diff --git a/npm-flexjs/dependencies/FlashPlayerGlobal.js b/npm-flexjs/dependencies/FlashPlayerGlobal.js new file mode 100644 index 0000000..5daad06 --- /dev/null +++ b/npm-flexjs/dependencies/FlashPlayerGlobal.js @@ -0,0 +1,86 @@ +/* + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + + +var request = require('request'); +var fs = require('fs'); +var events = require('events'); +var prompt = require('prompt'); + +var constants = require('../dependencies/Constants'); + +var FlashPlayerGlobal = module.exports = Object.create(events.EventEmitter.prototype); + +var flashPlayerGlobalURL = 'http://download.macromedia.com/get/flashplayer/updaters/19/'; +var fileNameFlashPlayerGlobal = 'playerglobal19_0.swc'; +var flashPlayerGlobalPromptText = "\ + Apache Flex SDK uses the Adobe Flash Player's playerglobal.swc to build Adobe Flash applications.\n\ + \n\ + The playerglobal.swc file is subject to and governed by the\n\ + Adobe Flex SDK License Agreement specified here:\n\ + http://www.adobe.com/products/eulas/pdfs/adobe_flex_software_development_kit-combined-20110916_0930.pdf,\n\ + By downloading, modifying, distributing, using and/or accessing the playerglobal.swc file\n\ + you agree to the terms and conditions of the applicable end user license agreement.\n\ + \n\ + In addition to the Adobe license terms, you also agree to be bound by the third-party terms specified here:\n\ + http://www.adobe.com/products/eula/third_party/.\n\ + Adobe recommends that you review these third-party terms.\n\ + \n\ + This license is not compatible with the Apache v2 license.\n\ + Do you want to download and install the playerglobal.swc? (y/n)"; + +FlashPlayerGlobal.promptForFlashPlayerGlobal = function() +{ + var schema = { + properties: { + accept: { + description: flashPlayerGlobalPromptText.cyan, + pattern: /^[YNyn\s]{1}$/, + message: 'Please respond with either y or n'.red, + required: true + } + } + }; + prompt.start(); + prompt.get(schema, function (err, result) { + console.log(' accept?: ' + result.accept); + if(result.accept.toLowerCase() == 'y') + { + FlashPlayerGlobal.downloadFlashPlayerGlobal(); + } + }); +}; + +FlashPlayerGlobal.downloadFlashPlayerGlobal = function() +{ + console.log('Downloading Adobe FlashPlayerGlobal.swc '); + request + .get(flashPlayerGlobalURL + fileNameFlashPlayerGlobal) + .pipe(fs.createWriteStream(constants.DOWNLOADS_FOLDER + '//' + fileNameFlashPlayerGlobal) + .on('finish', function(){ + console.log('FlashPlayerGlobal download complete'); + FlashPlayerGlobal.emit('complete'); + }) + ); +}; + +FlashPlayerGlobal.install = function() +{ + FlashPlayerGlobal.promptForFlashPlayerGlobal(); +}; \ No newline at end of file http://git-wip-us.apache.org/repos/asf/flex-utilities/blob/490f9109/npm-flexjs/dependencies/SWFObject.js ---------------------------------------------------------------------- diff --git a/npm-flexjs/dependencies/SWFObject.js b/npm-flexjs/dependencies/SWFObject.js new file mode 100644 index 0000000..6a4934d --- /dev/null +++ b/npm-flexjs/dependencies/SWFObject.js @@ -0,0 +1,49 @@ +/* + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + + +var request = require('request'); +var fs = require('fs'); +var events = require('events'); + +var constants = require('../dependencies/Constants'); + +var SWFObject = module.exports = Object.create(events.EventEmitter.prototype); + +//SWFObject +var swfObjectURL = 'https://github.com/swfobject/swfobject/archive/2.2.zip'; +var fileNameSwfObject = 'swfobject_2_2.zip'; + +SWFObject.downloadSwfObject = function() +{ + console.log('Downloading SWFObject'); + request + .get(swfObjectURL) + .pipe(fs.createWriteStream(constants.DOWNLOADS_FOLDER + '//' + fileNameSwfObject) + .on('finish', function(){ + console.log('SWFObject download complete'); + SWFObject.emit('complete'); + }) + ); +}; + +SWFObject.install = function() +{ + SWFObject.downloadSwfObject(); +}; \ No newline at end of file http://git-wip-us.apache.org/repos/asf/flex-utilities/blob/490f9109/npm-flexjs/download_dependencies.js ---------------------------------------------------------------------- diff --git a/npm-flexjs/download_dependencies.js b/npm-flexjs/download_dependencies.js new file mode 100644 index 0000000..d2cb82e --- /dev/null +++ b/npm-flexjs/download_dependencies.js @@ -0,0 +1,79 @@ +/* + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + +'use strict'; + +var fs = require('fs'); +var constants = require('./dependencies/Constants'); +var adobeair = require('./dependencies/AdobeAIR'); +var flashplayerglobal = require('./dependencies/FlashPlayerGlobal'); +var apacheFlexJS = require('./dependencies/ApacheFlexJS'); +var apacheFalcon = require('./dependencies/ApacheFalcon'); +var swfObject = require('./dependencies/SWFObject'); + +function createDownloadsDirectory() +{ + //Create downloads directory if it does not exist already + try + { + fs.mkdirSync(constants.DOWNLOADS_FOLDER); + } + catch(e) + { + if ( e.code != 'EEXIST' ) throw e; + } +} + +function handleFlashPlayerGlobalComplete(event) +{ + adobeair.on('complete', handleAdobeAIRComplete); + adobeair.install(); +} + +function handleAdobeAIRComplete(event) +{ + apacheFlexJS.on('complete', handleApacheFlexJSComplete); + apacheFlexJS.install(); +} + +function handleApacheFlexJSComplete(event) +{ + apacheFalcon.on('complete', handleApacheFalconComplete); + apacheFalcon.install(); +} + +function handleApacheFalconComplete(event) +{ + swfObject.on('complete', handleSwfObjectComplete); + swfObject.install(); +} + +function handleSwfObjectComplete(event) +{ + allDownloadsComplete(); +} + +function allDownloadsComplete() +{ + console.log('Completed all downloads'); +} + +createDownloadsDirectory(); +flashplayerglobal.on('complete', handleFlashPlayerGlobalComplete); +flashplayerglobal.install(); \ No newline at end of file http://git-wip-us.apache.org/repos/asf/flex-utilities/blob/490f9109/npm-flexjs/package.json ---------------------------------------------------------------------- diff --git a/npm-flexjs/package.json b/npm-flexjs/package.json index d19c3a0..d543f42 100644 --- a/npm-flexjs/package.json +++ b/npm-flexjs/package.json @@ -4,7 +4,8 @@ "description": "Apache FlexJS", "main": "index.js", "scripts": { - "test": "echo \"Error: no test specified\" && exit 1" + "test": "echo \"Error: no test specified\" && exit 1", + "preinstall": "node download_dependencies.js" }, "keywords": [ "flex", http://git-wip-us.apache.org/repos/asf/flex-utilities/blob/490f9109/npm-flexjs/prepublish.js ---------------------------------------------------------------------- diff --git a/npm-flexjs/prepublish.js b/npm-flexjs/prepublish.js deleted file mode 100644 index 1ac5d20..0000000 --- a/npm-flexjs/prepublish.js +++ /dev/null @@ -1,93 +0,0 @@ -'use strict'; - -var request = require('request'); -var fs = require('fs'); -var prompt = require('prompt'); - -var apacheMirrorsCGI = 'http://www.apache.org/dyn/mirrors/mirrors.cgi/'; - -//FlexJS -var pathToFlexJSBinary = 'flex/flexjs/0.5.0/binaries/'; -var fileNameFlexJSBinary = 'apache-flex-flexjs-0.5.0-bin.zip'; - -//Falcon -var pathToFalconBinary = 'flex/falcon/0.5.0/binaries/'; -var fileNameFalconBinary = 'apache-flex-falconjx-0.5.0-bin.zip'; - -//Adobe AIR -var AdobeAIRURL = 'http://airdownload.adobe.com/air/win/download/20.0/'; -var fileNameAdobeAIR = 'AdobeAIRSDK.zip'; - -//Flash Player Global - -var requestJSON = 'asjson=true'; - -var createDownloadsDirectory = function() -{ - try { - fs.mkdirSync('downloads'); - } catch(e) { - if ( e.code != 'EEXIST' ) throw e; - } -} - -var handleFlexJSMirrorsResponse = function (error, response, body) -{ - if (!error && response.statusCode == 200) - { - var mirrors = JSON.parse(body); - var flexJSPreferredDownloadURL = mirrors.preferred + pathToFlexJSBinary + fileNameFlexJSBinary; - //Download FlexJS - //request(this.flexJSPreferredDownloadURL, handleFlexJSBinaryResponse); - request - .get(flexJSPreferredDownloadURL) - .on('response', function(response) { - }) - .pipe(fs.createWriteStream('downloads//' + fileNameFlexJSBinary)); - } - -}; - -var handleFalconMirrorsResponse = function (error, response, body) -{ - if (!error && response.statusCode == 200) - { - var mirrors = JSON.parse(body); - var falconPreferredDownloadURL = mirrors.preferred + pathToFalconBinary + fileNameFalconBinary; - //Download Falcon - request - .get(falconPreferredDownloadURL) - .on('response', function(response) { - }) - .pipe(fs.createWriteStream('downloads//' + fileNameFalconBinary)); - } - -}; - -var promptForAdobeAIR = function() -{ - var schema = { - properties: { - accept: { - description: "Do you accept Adobe's license?", - pattern: /^[YNyn\s]{1}$/, - message: 'Please respond with either y or n', - required: true - } - } - }; - prompt.start(); - prompt.get(schema, function (err, result) { - console.log(' accept?: ' + result.accept); - }); -}; - -createDownloadsDirectory(); -request(apacheMirrorsCGI + pathToFlexJSBinary + fileNameFlexJSBinary + '?' + requestJSON, handleFlexJSMirrorsResponse); -request(apacheMirrorsCGI + pathToFalconBinary + fileNameFalconBinary + '?' + requestJSON, handleFalconMirrorsResponse); -promptForAdobeAIR(); -//promptForFlashPlayerGlobal(); - -//Download Adobe AIR - -//Download Flash Player Global \ No newline at end of file