Skip to content

Latest commit

 

History

History
36 lines (27 loc) · 743 Bytes

README.md

File metadata and controls

36 lines (27 loc) · 743 Bytes

mail-migrator

Easily migrate an email account to another server using NodeJS.

Usage

Create an index.js file, using index.example.js as a template:

const Migrator = require('../lib/Migrator')

const fromConfig = {
  host: 'myawesomesite.com',
  port: 993, 
  user: '[email protected]',
  pass: 'password',
  requireTLS: true
}

const toConfig = {
  host: 'myothersite.com',
  port: 993,
  user: '[email protected]',
  pass: 'password',
  requireTLS: true
}

const migrator = new Migrator(fromConfig, toConfig)

migrator.init().then(async () => {
  await migrator.migrate()
  console.log('migration complete')
})

Save the file and then run npm run dev (probably will be changed to a different command).