From abd2316113469daaa37ba0f2e7fadc278fb2996e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Greg=20Berg=C3=A9?= Date: Fri, 23 Mar 2018 14:02:37 +0000 Subject: [PATCH] fix: be compatible with CommonJS --- packages/shipit-cli/src/index.js | 4 +++- packages/shipit-deploy/src/index.js | 2 +- packages/ssh-pool/src/index.js | 13 +++++++++---- 3 files changed, 13 insertions(+), 6 deletions(-) diff --git a/packages/shipit-cli/src/index.js b/packages/shipit-cli/src/index.js index 17373e0..18fbdaa 100644 --- a/packages/shipit-cli/src/index.js +++ b/packages/shipit-cli/src/index.js @@ -1 +1,3 @@ -export { default } from './Shipit' +import Shipit from './Shipit' + +module.exports = Shipit diff --git a/packages/shipit-deploy/src/index.js b/packages/shipit-deploy/src/index.js index c8eb2ab..0e0afae 100644 --- a/packages/shipit-deploy/src/index.js +++ b/packages/shipit-deploy/src/index.js @@ -2,7 +2,7 @@ import deploy from './tasks/deploy' import rollback from './tasks/rollback' import pending from './tasks/pending' -export default shipit => { +module.exports = shipit => { deploy(shipit) rollback(shipit) pending(shipit) diff --git a/packages/ssh-pool/src/index.js b/packages/ssh-pool/src/index.js index 5882232..021e152 100644 --- a/packages/ssh-pool/src/index.js +++ b/packages/ssh-pool/src/index.js @@ -1,4 +1,9 @@ -export { default as Connection } from './Connection' -export { default as ConnectionPool } from './ConnectionPool' -export { exec } from './util' -export { isRsyncSupported } from './commands/rsync' +import Connection from './Connection' +import ConnectionPool from './ConnectionPool' +import { exec } from './util' +import { isRsyncSupported } from './commands/rsync' + +exports.Connection = Connection +exports.ConnectionPool = ConnectionPool +exports.exec = exec +exports.isRsyncSupported = isRsyncSupported