[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6F6G3SAJ1N1CJ1B3475NX1X":3,"skill-same:01M6F6G3SAJ1N1CJ1B3475NX1X":74},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":42,"linkOnly":43,"markdownContent":44,"markdownBody":45,"frontMatter":46,"refName":51,"commitSha":52,"skillDirectory":53,"forksCount":54,"repositoryHtmlUrl":55,"repositoryHomepageUrl":6,"ownerHtmlUrl":56,"ownerBlogUrl":57,"ownerDescription":58,"updatedAt":59,"install":60,"resources":73},"01M6F6G3SAJ1N1CJ1B3475NX1X","evernote-migration-deep-dive",null,"Deep dive into Evernote data migration strategies.\nUse when migrating to\u002Ffrom Evernote, bulk data transfers,\nor complex migration scenarios.\nTrigger with phrases like \"migrate to evernote\", \"migrate from evernote\",\n\"evernote data transfer\", \"bulk evernote migration\".","Dicklesworthstone\u002Fpi_agent_rust","Dicklesworthstone","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F35050222?v=4","01M6CG26AR942CSVMN1M5E3DSE","Jeff Emanuel","01M6CG26EPP71PSHW1VDS71121",1992,"MIT","https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust\u002Fblob\u002Fmain\u002Ftests\u002Fext_conformance\u002Fartifacts\u002Fplugins-community\u002Fplugins\u002Fsaas-packs\u002Fevernote-pack\u002Fskills\u002Fevernote-migration-deep-dive\u002FSKILL.md",[],[19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41],"deep dive","evernote","evernote migration deep dive","migration","deep","strategies","when","transfers","with","data migration","bulk","trigger","io","npm","use","edit","write","read","grep","migrate","Bash","data","transfer","2026-11-10 10:12:30",false,"---\nname: evernote-migration-deep-dive\ndescription: |\n  Deep dive into Evernote data migration strategies.\n  Use when migrating to\u002Ffrom Evernote, bulk data transfers,\n  or complex migration scenarios.\n  Trigger with phrases like \"migrate to evernote\", \"migrate from evernote\",\n  \"evernote data transfer\", \"bulk evernote migration\".\nallowed-tools: Read, Write, Edit, Bash(npm:*), Grep\nversion: 1.0.0\nlicense: MIT\nauthor: Jeremy Longshore \u003Cjeremy@intentsolutions.io>\n---\n\n# Evernote Migration Deep Dive\n\n## Overview\n\nComprehensive guide for migrating data to and from Evernote, including bulk operations, format conversions, and maintaining data integrity.\n\n## Prerequisites\n\n- Understanding of Evernote data model\n- Source\u002Ftarget system access\n- Sufficient API quota for migration\n- Backup strategy in place\n\n## Migration Scenarios\n\n| Scenario | Source | Target | Complexity |\n|----------|--------|--------|------------|\n| Import to Evernote | External | Evernote | Medium |\n| Export from Evernote | Evernote | External | Medium |\n| Evernote to Evernote | Account A | Account B | High |\n| Bulk archive | Evernote | Archive storage | Low |\n\n## Instructions\n\n### Step 1: Migration Planning\n\n```javascript\n\u002F\u002F migration\u002Fplanner.js\n\nclass MigrationPlanner {\n  constructor(sourceClient, targetConfig) {\n    this.source = sourceClient;\n    this.target = targetConfig;\n    this.plan = null;\n  }\n\n  \u002F**\n   * Analyze source data\n   *\u002F\n  async analyzeSource() {\n    const noteStore = this.source.getNoteStore();\n\n    \u002F\u002F Get all notebooks\n    const notebooks = await noteStore.listNotebooks();\n\n    \u002F\u002F Get all tags\n    const tags = await noteStore.listTags();\n\n    \u002F\u002F Count notes per notebook\n    const noteCounts = {};\n    for (const notebook of notebooks) {\n      const filter = new Evernote.NoteStore.NoteFilter({\n        notebookGuid: notebook.guid\n      });\n      const result = await noteStore.findNotesMetadata(\n        filter, 0, 1,\n        new Evernote.NoteStore.NotesMetadataResultSpec({})\n      );\n      noteCounts[notebook.guid] = result.totalNotes;\n    }\n\n    \u002F\u002F Estimate sizes\n    const analysis = {\n      notebooks: notebooks.length,\n      tags: tags.length,\n      totalNotes: Object.values(noteCounts).reduce((a, b) => a + b, 0),\n      notebookDetails: notebooks.map(nb => ({\n        guid: nb.guid,\n        name: nb.name,\n        noteCount: noteCounts[nb.guid]\n      })),\n      estimatedDuration: this.estimateDuration(Object.values(noteCounts).reduce((a, b) => a + b, 0)),\n      recommendations: []\n    };\n\n    \u002F\u002F Generate recommendations\n    if (analysis.totalNotes > 10000) {\n      analysis.recommendations.push('Consider incremental migration');\n    }\n    if (analysis.notebooks > 100) {\n      analysis.recommendations.push('Plan notebook mapping before migration');\n    }\n\n    return analysis;\n  }\n\n  \u002F**\n   * Estimate migration duration\n   *\u002F\n  estimateDuration(noteCount) {\n    \u002F\u002F Rough estimate: 1 note per second with rate limiting\n    const seconds = noteCount;\n    const hours = Math.ceil(seconds \u002F 3600);\n    return `Approximately ${hours} hour(s)`;\n  }\n\n  \u002F**\n   * Create migration plan\n   *\u002F\n  async createPlan(options = {}) {\n    const analysis = await this.analyzeSource();\n\n    this.plan = {\n      id: `migration-${Date.now()}`,\n      createdAt: new Date().toISOString(),\n      source: {\n        type: 'evernote',\n        analysis\n      },\n      target: this.target,\n      options: {\n        includeResources: options.includeResources ?? true,\n        preserveTags: options.preserveTags ?? true,\n        preserveTimestamps: options.preserveTimestamps ?? true,\n        notebookMapping: options.notebookMapping || {},\n        excludeNotebooks: options.excludeNotebooks || [],\n        batchSize: options.batchSize || 50,\n        concurrency: options.concurrency || 1\n      },\n      status: 'planned',\n      progress: {\n        total: analysis.totalNotes,\n        completed: 0,\n        failed: 0\n      }\n    };\n\n    return this.plan;\n  }\n}\n\nmodule.exports = MigrationPlanner;\n```\n\n### Step 2: Export from Evernote\n\n```javascript\n\u002F\u002F migration\u002Fevernote-exporter.js\nconst fs = require('fs').promises;\nconst path = require('path');\n\nclass EvernoteExporter {\n  constructor(noteStore, options = {}) {\n    this.noteStore = noteStore;\n    this.outputDir = options.outputDir || '.\u002Fexport';\n    this.format = options.format || 'enex'; \u002F\u002F enex, json, markdown\n  }\n\n  \u002F**\n   * Export all data\n   *\u002F\n  async exportAll(progressCallback) {\n    await fs.mkdir(this.outputDir, { recursive: true });\n\n    const notebooks = await this.noteStore.listNotebooks();\n    const tags = await this.noteStore.listTags();\n\n    \u002F\u002F Export metadata\n    await this.exportMetadata(notebooks, tags);\n\n    \u002F\u002F Export each notebook\n    let total = 0;\n    let exported = 0;\n\n    for (const notebook of notebooks) {\n      const noteCount = await this.exportNotebook(notebook, (progress) => {\n        progressCallback?.({\n          phase: 'notes',\n          notebook: notebook.name,\n          ...progress\n        });\n      });\n      total += noteCount;\n      exported += noteCount;\n    }\n\n    return {\n      notebooks: notebooks.length,\n      tags: tags.length,\n      notes: total,\n      outputDir: this.outputDir\n    };\n  }\n\n  \u002F**\n   * Export metadata\n   *\u002F\n  async exportMetadata(notebooks, tags) {\n    const metadata = {\n      exportedAt: new Date().toISOString(),\n      notebooks: notebooks.map(nb => ({\n        guid: nb.guid,\n        name: nb.name,\n        stack: nb.stack,\n        defaultNotebook: nb.defaultNotebook\n      })),\n      tags: tags.map(t => ({\n        guid: t.guid,\n        name: t.name,\n        parentGuid: t.parentGuid\n      }))\n    };\n\n    await fs.writeFile(\n      path.join(this.outputDir, 'metadata.json'),\n      JSON.stringify(metadata, null, 2)\n    );\n  }\n\n  \u002F**\n   * Export notebook\n   *\u002F\n  async exportNotebook(notebook, progressCallback) {\n    const notebookDir = path.join(this.outputDir, this.sanitizeName(notebook.name));\n    await fs.mkdir(notebookDir, { recursive: true });\n\n    const filter = new Evernote.NoteStore.NoteFilter({\n      notebookGuid: notebook.guid\n    });\n\n    const spec = new Evernote.NoteStore.NotesMetadataResultSpec({\n      includeTitle: true,\n      includeUpdated: true\n    });\n\n    \u002F\u002F Get note list\n    const result = await this.noteStore.findNotesMetadata(filter, 0, 10000, spec);\n    const total = result.notes.length;\n    let exported = 0;\n\n    for (const noteMeta of result.notes) {\n      try {\n        \u002F\u002F Get full note with resources\n        const note = await this.noteStore.getNote(\n          noteMeta.guid,\n          true,  \u002F\u002F withContent\n          true,  \u002F\u002F withResourcesData\n          false, \u002F\u002F withResourcesRecognition\n          false  \u002F\u002F withResourcesAlternateData\n        );\n\n        await this.exportNote(note, notebookDir);\n        exported++;\n\n        progressCallback?.({\n          current: exported,\n          total,\n          note: note.title\n        });\n\n        \u002F\u002F Rate limit protection\n        await this.sleep(100);\n\n      } catch (error) {\n        console.error(`Failed to export note ${noteMeta.guid}:`, error.message);\n      }\n    }\n\n    return exported;\n  }\n\n  \u002F**\n   * Export single note\n   *\u002F\n  async exportNote(note, outputDir) {\n    const noteDir = path.join(outputDir, this.sanitizeName(note.title) + '_' + note.guid.slice(0, 8));\n    await fs.mkdir(noteDir, { recursive: true });\n\n    switch (this.format) {\n      case 'json':\n        await this.exportAsJson(note, noteDir);\n        break;\n      case 'markdown':\n        await this.exportAsMarkdown(note, noteDir);\n        break;\n      case 'enex':\n      default:\n        await this.exportAsEnex(note, noteDir);\n    }\n\n    \u002F\u002F Export resources\n    if (note.resources) {\n      const resourcesDir = path.join(noteDir, 'resources');\n      await fs.mkdir(resourcesDir, { recursive: true });\n\n      for (const resource of note.resources) {\n        await this.exportResource(resource, resourcesDir);\n      }\n    }\n  }\n\n  \u002F**\n   * Export as JSON\n   *\u002F\n  async exportAsJson(note, outputDir) {\n    const data = {\n      guid: note.guid,\n      title: note.title,\n      content: note.content,\n      created: note.created,\n      updated: note.updated,\n      tagGuids: note.tagGuids,\n      resources: note.resources?.map(r => ({\n        guid: r.guid,\n        mime: r.mime,\n        fileName: r.attributes?.fileName,\n        hash: Buffer.from(r.data.bodyHash).toString('hex')\n      }))\n    };\n\n    await fs.writeFile(\n      path.join(outputDir, 'note.json'),\n      JSON.stringify(data, null, 2)\n    );\n  }\n\n  \u002F**\n   * Export as Markdown\n   *\u002F\n  async exportAsMarkdown(note, outputDir) {\n    let markdown = `# ${note.title}\\n\\n`;\n    markdown += `Created: ${new Date(note.created).toISOString()}\\n`;\n    markdown += `Updated: ${new Date(note.updated).toISOString()}\\n\\n`;\n    markdown += `---\\n\\n`;\n    markdown += this.enmlToMarkdown(note.content);\n\n    await fs.writeFile(\n      path.join(outputDir, 'note.md'),\n      markdown\n    );\n  }\n\n  \u002F**\n   * Convert ENML to Markdown\n   *\u002F\n  enmlToMarkdown(enml) {\n    let md = enml\n      \u002F\u002F Remove XML declaration and DOCTYPE\n      .replace(\u002F\u003C\\?xml[^>]*\\?>\u002Fg, '')\n      .replace(\u002F\u003C!DOCTYPE[^>]*>\u002Fg, '')\n      \u002F\u002F Remove en-note wrapper\n      .replace(\u002F\u003C\\\u002F?en-note[^>]*>\u002Fg, '')\n      \u002F\u002F Convert headers\n      .replace(\u002F\u003Ch1[^>]*>(.*?)\u003C\\\u002Fh1>\u002Fgi, '# $1\\n\\n')\n      .replace(\u002F\u003Ch2[^>]*>(.*?)\u003C\\\u002Fh2>\u002Fgi, '## $1\\n\\n')\n      .replace(\u002F\u003Ch3[^>]*>(.*?)\u003C\\\u002Fh3>\u002Fgi, '### $1\\n\\n')\n      \u002F\u002F Convert formatting\n      .replace(\u002F\u003Cb[^>]*>(.*?)\u003C\\\u002Fb>\u002Fgi, '**$1**')\n      .replace(\u002F\u003Cstrong[^>]*>(.*?)\u003C\\\u002Fstrong>\u002Fgi, '**$1**')\n      .replace(\u002F\u003Ci[^>]*>(.*?)\u003C\\\u002Fi>\u002Fgi, '*$1*')\n      .replace(\u002F\u003Cem[^>]*>(.*?)\u003C\\\u002Fem>\u002Fgi, '*$1*')\n      \u002F\u002F Convert links\n      .replace(\u002F\u003Ca[^>]*href=\"([^\"]*)\"[^>]*>(.*?)\u003C\\\u002Fa>\u002Fgi, '[$2]($1)')\n      \u002F\u002F Convert line breaks\n      .replace(\u002F\u003Cbr\\s*\\\u002F?>\u002Fgi, '\\n')\n      .replace(\u002F\u003C\\\u002Fp>\u002Fgi, '\\n\\n')\n      .replace(\u002F\u003Cp[^>]*>\u002Fgi, '')\n      \u002F\u002F Convert divs\n      .replace(\u002F\u003C\\\u002Fdiv>\u002Fgi, '\\n')\n      .replace(\u002F\u003Cdiv[^>]*>\u002Fgi, '')\n      \u002F\u002F Convert lists\n      .replace(\u002F\u003Cli[^>]*>\u002Fgi, '- ')\n      .replace(\u002F\u003C\\\u002Fli>\u002Fgi, '\\n')\n      .replace(\u002F\u003C\\\u002F?[uo]l[^>]*>\u002Fgi, '\\n')\n      \u002F\u002F Convert todos\n      .replace(\u002F\u003Cen-todo\\s+checked=\"false\"\\s*\\\u002F>\u002Fgi, '[ ] ')\n      .replace(\u002F\u003Cen-todo\\s+checked=\"true\"\\s*\\\u002F>\u002Fgi, '[x] ')\n      \u002F\u002F Convert media references\n      .replace(\u002F\u003Cen-media[^>]*hash=\"([^\"]*)\"[^>]*\\\u002F>\u002Fgi, '\\n![attachment]($1)\\n')\n      \u002F\u002F Remove remaining tags\n      .replace(\u002F\u003C[^>]+>\u002Fg, '')\n      \u002F\u002F Decode entities\n      .replace(\u002F&amp;\u002Fg, '&')\n      .replace(\u002F&lt;\u002Fg, '\u003C')\n      .replace(\u002F&gt;\u002Fg, '>')\n      .replace(\u002F&quot;\u002Fg, '\"')\n      .replace(\u002F&nbsp;\u002Fg, ' ')\n      \u002F\u002F Clean up whitespace\n      .replace(\u002F\\n{3,}\u002Fg, '\\n\\n')\n      .trim();\n\n    return md;\n  }\n\n  \u002F**\n   * Export resource\n   *\u002F\n  async exportResource(resource, outputDir) {\n    const hash = Buffer.from(resource.data.bodyHash).toString('hex');\n    const ext = this.getExtension(resource.mime);\n    const fileName = resource.attributes?.fileName || `${hash}${ext}`;\n\n    await fs.writeFile(\n      path.join(outputDir, fileName),\n      resource.data.body\n    );\n  }\n\n  sanitizeName(name) {\n    return name\n      .replace(\u002F[\u003C>:\"\u002F\\\\|?*]\u002Fg, '_')\n      .replace(\u002F\\s+\u002Fg, '_')\n      .slice(0, 100);\n  }\n\n  getExtension(mimeType) {\n    const map = {\n      'image\u002Fpng': '.png',\n      'image\u002Fjpeg': '.jpg',\n      'image\u002Fgif': '.gif',\n      'application\u002Fpdf': '.pdf'\n    };\n    return map[mimeType] || '';\n  }\n\n  sleep(ms) {\n    return new Promise(resolve => setTimeout(resolve, ms));\n  }\n}\n\nmodule.exports = EvernoteExporter;\n```\n\n### Step 3: Import to Evernote\n\n```javascript\n\u002F\u002F migration\u002Fevernote-importer.js\nconst fs = require('fs').promises;\nconst path = require('path');\nconst crypto = require('crypto');\n\nclass EvernoteImporter {\n  constructor(noteStore, options = {}) {\n    this.noteStore = noteStore;\n    this.batchSize = options.batchSize || 10;\n    this.notebookMapping = new Map();\n    this.tagMapping = new Map();\n  }\n\n  \u002F**\n   * Import from export directory\n   *\u002F\n  async importFromDirectory(sourceDir, progressCallback) {\n    \u002F\u002F Load metadata\n    const metadataPath = path.join(sourceDir, 'metadata.json');\n    const metadata = JSON.parse(await fs.readFile(metadataPath, 'utf8'));\n\n    \u002F\u002F Create notebooks\n    await this.createNotebooks(metadata.notebooks);\n\n    \u002F\u002F Create tags\n    await this.createTags(metadata.tags);\n\n    \u002F\u002F Import notes\n    const notebooks = await fs.readdir(sourceDir, { withFileTypes: true });\n    let totalImported = 0;\n\n    for (const entry of notebooks) {\n      if (entry.isDirectory() && entry.name !== 'metadata.json') {\n        const notebookDir = path.join(sourceDir, entry.name);\n        const imported = await this.importNotebook(notebookDir, entry.name, progressCallback);\n        totalImported += imported;\n      }\n    }\n\n    return { imported: totalImported };\n  }\n\n  \u002F**\n   * Create notebooks (with deduplication)\n   *\u002F\n  async createNotebooks(notebooks) {\n    const existing = await this.noteStore.listNotebooks();\n    const existingMap = new Map(existing.map(nb => [nb.name.toLowerCase(), nb]));\n\n    for (const nb of notebooks) {\n      const existingNb = existingMap.get(nb.name.toLowerCase());\n\n      if (existingNb) {\n        this.notebookMapping.set(nb.guid, existingNb.guid);\n      } else {\n        const newNb = new Evernote.Types.Notebook();\n        newNb.name = nb.name;\n        if (nb.stack) newNb.stack = nb.stack;\n\n        const created = await this.noteStore.createNotebook(newNb);\n        this.notebookMapping.set(nb.guid, created.guid);\n      }\n    }\n  }\n\n  \u002F**\n   * Create tags (with deduplication)\n   *\u002F\n  async createTags(tags) {\n    const existing = await this.noteStore.listTags();\n    const existingMap = new Map(existing.map(t => [t.name.toLowerCase(), t]));\n\n    for (const tag of tags) {\n      const existingTag = existingMap.get(tag.name.toLowerCase());\n\n      if (existingTag) {\n        this.tagMapping.set(tag.guid, existingTag.guid);\n      } else {\n        const newTag = new Evernote.Types.Tag();\n        newTag.name = tag.name;\n\n        const created = await this.noteStore.createTag(newTag);\n        this.tagMapping.set(tag.guid, created.guid);\n      }\n    }\n  }\n\n  \u002F**\n   * Import notebook directory\n   *\u002F\n  async importNotebook(notebookDir, notebookName, progressCallback) {\n    const notes = await fs.readdir(notebookDir, { withFileTypes: true });\n    const noteDirs = notes.filter(e => e.isDirectory());\n    let imported = 0;\n\n    for (const noteEntry of noteDirs) {\n      try {\n        const noteDir = path.join(notebookDir, noteEntry.name);\n        await this.importNote(noteDir);\n        imported++;\n\n        progressCallback?.({\n          notebook: notebookName,\n          current: imported,\n          total: noteDirs.length\n        });\n\n        \u002F\u002F Rate limiting\n        await this.sleep(200);\n\n      } catch (error) {\n        console.error(`Failed to import note ${noteEntry.name}:`, error.message);\n      }\n    }\n\n    return imported;\n  }\n\n  \u002F**\n   * Import single note\n   *\u002F\n  async importNote(noteDir) {\n    const jsonPath = path.join(noteDir, 'note.json');\n    const data = JSON.parse(await fs.readFile(jsonPath, 'utf8'));\n\n    const note = new Evernote.Types.Note();\n    note.title = data.title;\n    note.content = data.content;\n\n    \u002F\u002F Map notebook\n    if (data.notebookGuid && this.notebookMapping.has(data.notebookGuid)) {\n      note.notebookGuid = this.notebookMapping.get(data.notebookGuid);\n    }\n\n    \u002F\u002F Map tags\n    if (data.tagGuids) {\n      note.tagGuids = data.tagGuids\n        .map(guid => this.tagMapping.get(guid))\n        .filter(Boolean);\n    }\n\n    \u002F\u002F Import resources\n    if (data.resources) {\n      note.resources = [];\n      const resourcesDir = path.join(noteDir, 'resources');\n\n      for (const resMeta of data.resources) {\n        try {\n          const resource = await this.createResource(resourcesDir, resMeta);\n          if (resource) {\n            note.resources.push(resource);\n          }\n        } catch (error) {\n          console.error(`Failed to import resource:`, error.message);\n        }\n      }\n    }\n\n    return this.noteStore.createNote(note);\n  }\n\n  \u002F**\n   * Create resource from file\n   *\u002F\n  async createResource(resourcesDir, metadata) {\n    const files = await fs.readdir(resourcesDir);\n    const matchingFile = files.find(f =>\n      f.includes(metadata.hash) || f === metadata.fileName\n    );\n\n    if (!matchingFile) {\n      console.warn(`Resource file not found: ${metadata.hash}`);\n      return null;\n    }\n\n    const filePath = path.join(resourcesDir, matchingFile);\n    const fileData = await fs.readFile(filePath);\n    const hash = crypto.createHash('md5').update(fileData).digest();\n\n    const resource = new Evernote.Types.Resource();\n    resource.mime = metadata.mime;\n    resource.data = new Evernote.Types.Data();\n    resource.data.body = fileData;\n    resource.data.size = fileData.length;\n    resource.data.bodyHash = hash;\n\n    if (metadata.fileName) {\n      resource.attributes = new Evernote.Types.ResourceAttributes();\n      resource.attributes.fileName = metadata.fileName;\n    }\n\n    return resource;\n  }\n\n  sleep(ms) {\n    return new Promise(resolve => setTimeout(resolve, ms));\n  }\n}\n\nmodule.exports = EvernoteImporter;\n```\n\n### Step 4: Migration Runner\n\n```javascript\n\u002F\u002F migration\u002Frunner.js\n\nclass MigrationRunner {\n  constructor(plan, exporter, importer) {\n    this.plan = plan;\n    this.exporter = exporter;\n    this.importer = importer;\n    this.status = 'pending';\n    this.startTime = null;\n    this.endTime = null;\n    this.errors = [];\n  }\n\n  \u002F**\n   * Run migration\n   *\u002F\n  async run(progressCallback) {\n    this.status = 'running';\n    this.startTime = Date.now();\n\n    try {\n      \u002F\u002F Phase 1: Export\n      progressCallback?.({ phase: 'export', status: 'starting' });\n\n      const exportResult = await this.exporter.exportAll((progress) => {\n        progressCallback?.({ phase: 'export', ...progress });\n      });\n\n      progressCallback?.({ phase: 'export', status: 'complete', result: exportResult });\n\n      \u002F\u002F Phase 2: Import\n      progressCallback?.({ phase: 'import', status: 'starting' });\n\n      const importResult = await this.importer.importFromDirectory(\n        this.exporter.outputDir,\n        (progress) => {\n          progressCallback?.({ phase: 'import', ...progress });\n        }\n      );\n\n      progressCallback?.({ phase: 'import', status: 'complete', result: importResult });\n\n      \u002F\u002F Phase 3: Verify\n      progressCallback?.({ phase: 'verify', status: 'starting' });\n      const verifyResult = await this.verify();\n      progressCallback?.({ phase: 'verify', status: 'complete', result: verifyResult });\n\n      this.status = 'completed';\n\n    } catch (error) {\n      this.status = 'failed';\n      this.errors.push(error.message);\n      throw error;\n\n    } finally {\n      this.endTime = Date.now();\n    }\n\n    return this.getReport();\n  }\n\n  \u002F**\n   * Verify migration\n   *\u002F\n  async verify() {\n    \u002F\u002F Count notes in target\n    \u002F\u002F Compare with source count\n    \u002F\u002F Return verification status\n    return { verified: true };\n  }\n\n  \u002F**\n   * Get migration report\n   *\u002F\n  getReport() {\n    return {\n      planId: this.plan.id,\n      status: this.status,\n      startTime: new Date(this.startTime).toISOString(),\n      endTime: this.endTime ? new Date(this.endTime).toISOString() : null,\n      duration: this.endTime ? `${((this.endTime - this.startTime) \u002F 1000 \u002F 60).toFixed(1)} minutes` : null,\n      errors: this.errors\n    };\n  }\n}\n\nmodule.exports = MigrationRunner;\n```\n\n## Output\n\n- Migration planning tools\n- Evernote data exporter (JSON, Markdown, ENEX)\n- Evernote data importer\n- Migration runner with progress tracking\n- Verification and reporting\n\n## Migration Checklist\n\n```markdown\n## Pre-Migration\n- [ ] Analyze source data\n- [ ] Create migration plan\n- [ ] Backup source data\n- [ ] Test with small dataset\n- [ ] Verify API quota\n\n## During Migration\n- [ ] Monitor progress\n- [ ] Check for errors\n- [ ] Handle rate limits\n- [ ] Log all operations\n\n## Post-Migration\n- [ ] Verify data integrity\n- [ ] Compare counts\n- [ ] Test functionality\n- [ ] Document results\n- [ ] Clean up temporary files\n```\n\n## Resources\n\n- [Evernote Export Format (ENEX)](https:\u002F\u002Fdev.evernote.com\u002Fdoc\u002Farticles\u002Fenex.php)\n- [ENML Reference](https:\u002F\u002Fdev.evernote.com\u002Fdoc\u002Farticles\u002Fenml.php)\n- [API Reference](https:\u002F\u002Fdev.evernote.com\u002Fdoc\u002Freference\u002F)\n\n## Support\n\nFor complex migrations, consider contacting Evernote Business support or professional services.\n","# Evernote Migration Deep Dive\n\n## Overview\n\nComprehensive guide for migrating data to and from Evernote, including bulk operations, format conversions, and maintaining data integrity.\n\n## Prerequisites\n\n- Understanding of Evernote data model\n- Source\u002Ftarget system access\n- Sufficient API quota for migration\n- Backup strategy in place\n\n## Migration Scenarios\n\n| Scenario | Source | Target | Complexity |\n|----------|--------|--------|------------|\n| Import to Evernote | External | Evernote | Medium |\n| Export from Evernote | Evernote | External | Medium |\n| Evernote to Evernote | Account A | Account B | High |\n| Bulk archive | Evernote | Archive storage | Low |\n\n## Instructions\n\n### Step 1: Migration Planning\n\n```javascript\n\u002F\u002F migration\u002Fplanner.js\n\nclass MigrationPlanner {\n  constructor(sourceClient, targetConfig) {\n    this.source = sourceClient;\n    this.target = targetConfig;\n    this.plan = null;\n  }\n\n  \u002F**\n   * Analyze source data\n   *\u002F\n  async analyzeSource() {\n    const noteStore = this.source.getNoteStore();\n\n    \u002F\u002F Get all notebooks\n    const notebooks = await noteStore.listNotebooks();\n\n    \u002F\u002F Get all tags\n    const tags = await noteStore.listTags();\n\n    \u002F\u002F Count notes per notebook\n    const noteCounts = {};\n    for (const notebook of notebooks) {\n      const filter = new Evernote.NoteStore.NoteFilter({\n        notebookGuid: notebook.guid\n      });\n      const result = await noteStore.findNotesMetadata(\n        filter, 0, 1,\n        new Evernote.NoteStore.NotesMetadataResultSpec({})\n      );\n      noteCounts[notebook.guid] = result.totalNotes;\n    }\n\n    \u002F\u002F Estimate sizes\n    const analysis = {\n      notebooks: notebooks.length,\n      tags: tags.length,\n      totalNotes: Object.values(noteCounts).reduce((a, b) => a + b, 0),\n      notebookDetails: notebooks.map(nb => ({\n        guid: nb.guid,\n        name: nb.name,\n        noteCount: noteCounts[nb.guid]\n      })),\n      estimatedDuration: this.estimateDuration(Object.values(noteCounts).reduce((a, b) => a + b, 0)),\n      recommendations: []\n    };\n\n    \u002F\u002F Generate recommendations\n    if (analysis.totalNotes > 10000) {\n      analysis.recommendations.push('Consider incremental migration');\n    }\n    if (analysis.notebooks > 100) {\n      analysis.recommendations.push('Plan notebook mapping before migration');\n    }\n\n    return analysis;\n  }\n\n  \u002F**\n   * Estimate migration duration\n   *\u002F\n  estimateDuration(noteCount) {\n    \u002F\u002F Rough estimate: 1 note per second with rate limiting\n    const seconds = noteCount;\n    const hours = Math.ceil(seconds \u002F 3600);\n    return `Approximately ${hours} hour(s)`;\n  }\n\n  \u002F**\n   * Create migration plan\n   *\u002F\n  async createPlan(options = {}) {\n    const analysis = await this.analyzeSource();\n\n    this.plan = {\n      id: `migration-${Date.now()}`,\n      createdAt: new Date().toISOString(),\n      source: {\n        type: 'evernote',\n        analysis\n      },\n      target: this.target,\n      options: {\n        includeResources: options.includeResources ?? true,\n        preserveTags: options.preserveTags ?? true,\n        preserveTimestamps: options.preserveTimestamps ?? true,\n        notebookMapping: options.notebookMapping || {},\n        excludeNotebooks: options.excludeNotebooks || [],\n        batchSize: options.batchSize || 50,\n        concurrency: options.concurrency || 1\n      },\n      status: 'planned',\n      progress: {\n        total: analysis.totalNotes,\n        completed: 0,\n        failed: 0\n      }\n    };\n\n    return this.plan;\n  }\n}\n\nmodule.exports = MigrationPlanner;\n```\n\n### Step 2: Export from Evernote\n\n```javascript\n\u002F\u002F migration\u002Fevernote-exporter.js\nconst fs = require('fs').promises;\nconst path = require('path');\n\nclass EvernoteExporter {\n  constructor(noteStore, options = {}) {\n    this.noteStore = noteStore;\n    this.outputDir = options.outputDir || '.\u002Fexport';\n    this.format = options.format || 'enex'; \u002F\u002F enex, json, markdown\n  }\n\n  \u002F**\n   * Export all data\n   *\u002F\n  async exportAll(progressCallback) {\n    await fs.mkdir(this.outputDir, { recursive: true });\n\n    const notebooks = await this.noteStore.listNotebooks();\n    const tags = await this.noteStore.listTags();\n\n    \u002F\u002F Export metadata\n    await this.exportMetadata(notebooks, tags);\n\n    \u002F\u002F Export each notebook\n    let total = 0;\n    let exported = 0;\n\n    for (const notebook of notebooks) {\n      const noteCount = await this.exportNotebook(notebook, (progress) => {\n        progressCallback?.({\n          phase: 'notes',\n          notebook: notebook.name,\n          ...progress\n        });\n      });\n      total += noteCount;\n      exported += noteCount;\n    }\n\n    return {\n      notebooks: notebooks.length,\n      tags: tags.length,\n      notes: total,\n      outputDir: this.outputDir\n    };\n  }\n\n  \u002F**\n   * Export metadata\n   *\u002F\n  async exportMetadata(notebooks, tags) {\n    const metadata = {\n      exportedAt: new Date().toISOString(),\n      notebooks: notebooks.map(nb => ({\n        guid: nb.guid,\n        name: nb.name,\n        stack: nb.stack,\n        defaultNotebook: nb.defaultNotebook\n      })),\n      tags: tags.map(t => ({\n        guid: t.guid,\n        name: t.name,\n        parentGuid: t.parentGuid\n      }))\n    };\n\n    await fs.writeFile(\n      path.join(this.outputDir, 'metadata.json'),\n      JSON.stringify(metadata, null, 2)\n    );\n  }\n\n  \u002F**\n   * Export notebook\n   *\u002F\n  async exportNotebook(notebook, progressCallback) {\n    const notebookDir = path.join(this.outputDir, this.sanitizeName(notebook.name));\n    await fs.mkdir(notebookDir, { recursive: true });\n\n    const filter = new Evernote.NoteStore.NoteFilter({\n      notebookGuid: notebook.guid\n    });\n\n    const spec = new Evernote.NoteStore.NotesMetadataResultSpec({\n      includeTitle: true,\n      includeUpdated: true\n    });\n\n    \u002F\u002F Get note list\n    const result = await this.noteStore.findNotesMetadata(filter, 0, 10000, spec);\n    const total = result.notes.length;\n    let exported = 0;\n\n    for (const noteMeta of result.notes) {\n      try {\n        \u002F\u002F Get full note with resources\n        const note = await this.noteStore.getNote(\n          noteMeta.guid,\n          true,  \u002F\u002F withContent\n          true,  \u002F\u002F withResourcesData\n          false, \u002F\u002F withResourcesRecognition\n          false  \u002F\u002F withResourcesAlternateData\n        );\n\n        await this.exportNote(note, notebookDir);\n        exported++;\n\n        progressCallback?.({\n          current: exported,\n          total,\n          note: note.title\n        });\n\n        \u002F\u002F Rate limit protection\n        await this.sleep(100);\n\n      } catch (error) {\n        console.error(`Failed to export note ${noteMeta.guid}:`, error.message);\n      }\n    }\n\n    return exported;\n  }\n\n  \u002F**\n   * Export single note\n   *\u002F\n  async exportNote(note, outputDir) {\n    const noteDir = path.join(outputDir, this.sanitizeName(note.title) + '_' + note.guid.slice(0, 8));\n    await fs.mkdir(noteDir, { recursive: true });\n\n    switch (this.format) {\n      case 'json':\n        await this.exportAsJson(note, noteDir);\n        break;\n      case 'markdown':\n        await this.exportAsMarkdown(note, noteDir);\n        break;\n      case 'enex':\n      default:\n        await this.exportAsEnex(note, noteDir);\n    }\n\n    \u002F\u002F Export resources\n    if (note.resources) {\n      const resourcesDir = path.join(noteDir, 'resources');\n      await fs.mkdir(resourcesDir, { recursive: true });\n\n      for (const resource of note.resources) {\n        await this.exportResource(resource, resourcesDir);\n      }\n    }\n  }\n\n  \u002F**\n   * Export as JSON\n   *\u002F\n  async exportAsJson(note, outputDir) {\n    const data = {\n      guid: note.guid,\n      title: note.title,\n      content: note.content,\n      created: note.created,\n      updated: note.updated,\n      tagGuids: note.tagGuids,\n      resources: note.resources?.map(r => ({\n        guid: r.guid,\n        mime: r.mime,\n        fileName: r.attributes?.fileName,\n        hash: Buffer.from(r.data.bodyHash).toString('hex')\n      }))\n    };\n\n    await fs.writeFile(\n      path.join(outputDir, 'note.json'),\n      JSON.stringify(data, null, 2)\n    );\n  }\n\n  \u002F**\n   * Export as Markdown\n   *\u002F\n  async exportAsMarkdown(note, outputDir) {\n    let markdown = `# ${note.title}\\n\\n`;\n    markdown += `Created: ${new Date(note.created).toISOString()}\\n`;\n    markdown += `Updated: ${new Date(note.updated).toISOString()}\\n\\n`;\n    markdown += `---\\n\\n`;\n    markdown += this.enmlToMarkdown(note.content);\n\n    await fs.writeFile(\n      path.join(outputDir, 'note.md'),\n      markdown\n    );\n  }\n\n  \u002F**\n   * Convert ENML to Markdown\n   *\u002F\n  enmlToMarkdown(enml) {\n    let md = enml\n      \u002F\u002F Remove XML declaration and DOCTYPE\n      .replace(\u002F\u003C\\?xml[^>]*\\?>\u002Fg, '')\n      .replace(\u002F\u003C!DOCTYPE[^>]*>\u002Fg, '')\n      \u002F\u002F Remove en-note wrapper\n      .replace(\u002F\u003C\\\u002F?en-note[^>]*>\u002Fg, '')\n      \u002F\u002F Convert headers\n      .replace(\u002F\u003Ch1[^>]*>(.*?)\u003C\\\u002Fh1>\u002Fgi, '# $1\\n\\n')\n      .replace(\u002F\u003Ch2[^>]*>(.*?)\u003C\\\u002Fh2>\u002Fgi, '## $1\\n\\n')\n      .replace(\u002F\u003Ch3[^>]*>(.*?)\u003C\\\u002Fh3>\u002Fgi, '### $1\\n\\n')\n      \u002F\u002F Convert formatting\n      .replace(\u002F\u003Cb[^>]*>(.*?)\u003C\\\u002Fb>\u002Fgi, '**$1**')\n      .replace(\u002F\u003Cstrong[^>]*>(.*?)\u003C\\\u002Fstrong>\u002Fgi, '**$1**')\n      .replace(\u002F\u003Ci[^>]*>(.*?)\u003C\\\u002Fi>\u002Fgi, '*$1*')\n      .replace(\u002F\u003Cem[^>]*>(.*?)\u003C\\\u002Fem>\u002Fgi, '*$1*')\n      \u002F\u002F Convert links\n      .replace(\u002F\u003Ca[^>]*href=\"([^\"]*)\"[^>]*>(.*?)\u003C\\\u002Fa>\u002Fgi, '[$2]($1)')\n      \u002F\u002F Convert line breaks\n      .replace(\u002F\u003Cbr\\s*\\\u002F?>\u002Fgi, '\\n')\n      .replace(\u002F\u003C\\\u002Fp>\u002Fgi, '\\n\\n')\n      .replace(\u002F\u003Cp[^>]*>\u002Fgi, '')\n      \u002F\u002F Convert divs\n      .replace(\u002F\u003C\\\u002Fdiv>\u002Fgi, '\\n')\n      .replace(\u002F\u003Cdiv[^>]*>\u002Fgi, '')\n      \u002F\u002F Convert lists\n      .replace(\u002F\u003Cli[^>]*>\u002Fgi, '- ')\n      .replace(\u002F\u003C\\\u002Fli>\u002Fgi, '\\n')\n      .replace(\u002F\u003C\\\u002F?[uo]l[^>]*>\u002Fgi, '\\n')\n      \u002F\u002F Convert todos\n      .replace(\u002F\u003Cen-todo\\s+checked=\"false\"\\s*\\\u002F>\u002Fgi, '[ ] ')\n      .replace(\u002F\u003Cen-todo\\s+checked=\"true\"\\s*\\\u002F>\u002Fgi, '[x] ')\n      \u002F\u002F Convert media references\n      .replace(\u002F\u003Cen-media[^>]*hash=\"([^\"]*)\"[^>]*\\\u002F>\u002Fgi, '\\n![attachment]($1)\\n')\n      \u002F\u002F Remove remaining tags\n      .replace(\u002F\u003C[^>]+>\u002Fg, '')\n      \u002F\u002F Decode entities\n      .replace(\u002F&amp;\u002Fg, '&')\n      .replace(\u002F&lt;\u002Fg, '\u003C')\n      .replace(\u002F&gt;\u002Fg, '>')\n      .replace(\u002F&quot;\u002Fg, '\"')\n      .replace(\u002F&nbsp;\u002Fg, ' ')\n      \u002F\u002F Clean up whitespace\n      .replace(\u002F\\n{3,}\u002Fg, '\\n\\n')\n      .trim();\n\n    return md;\n  }\n\n  \u002F**\n   * Export resource\n   *\u002F\n  async exportResource(resource, outputDir) {\n    const hash = Buffer.from(resource.data.bodyHash).toString('hex');\n    const ext = this.getExtension(resource.mime);\n    const fileName = resource.attributes?.fileName || `${hash}${ext}`;\n\n    await fs.writeFile(\n      path.join(outputDir, fileName),\n      resource.data.body\n    );\n  }\n\n  sanitizeName(name) {\n    return name\n      .replace(\u002F[\u003C>:\"\u002F\\\\|?*]\u002Fg, '_')\n      .replace(\u002F\\s+\u002Fg, '_')\n      .slice(0, 100);\n  }\n\n  getExtension(mimeType) {\n    const map = {\n      'image\u002Fpng': '.png',\n      'image\u002Fjpeg': '.jpg',\n      'image\u002Fgif': '.gif',\n      'application\u002Fpdf': '.pdf'\n    };\n    return map[mimeType] || '';\n  }\n\n  sleep(ms) {\n    return new Promise(resolve => setTimeout(resolve, ms));\n  }\n}\n\nmodule.exports = EvernoteExporter;\n```\n\n### Step 3: Import to Evernote\n\n```javascript\n\u002F\u002F migration\u002Fevernote-importer.js\nconst fs = require('fs').promises;\nconst path = require('path');\nconst crypto = require('crypto');\n\nclass EvernoteImporter {\n  constructor(noteStore, options = {}) {\n    this.noteStore = noteStore;\n    this.batchSize = options.batchSize || 10;\n    this.notebookMapping = new Map();\n    this.tagMapping = new Map();\n  }\n\n  \u002F**\n   * Import from export directory\n   *\u002F\n  async importFromDirectory(sourceDir, progressCallback) {\n    \u002F\u002F Load metadata\n    const metadataPath = path.join(sourceDir, 'metadata.json');\n    const metadata = JSON.parse(await fs.readFile(metadataPath, 'utf8'));\n\n    \u002F\u002F Create notebooks\n    await this.createNotebooks(metadata.notebooks);\n\n    \u002F\u002F Create tags\n    await this.createTags(metadata.tags);\n\n    \u002F\u002F Import notes\n    const notebooks = await fs.readdir(sourceDir, { withFileTypes: true });\n    let totalImported = 0;\n\n    for (const entry of notebooks) {\n      if (entry.isDirectory() && entry.name !== 'metadata.json') {\n        const notebookDir = path.join(sourceDir, entry.name);\n        const imported = await this.importNotebook(notebookDir, entry.name, progressCallback);\n        totalImported += imported;\n      }\n    }\n\n    return { imported: totalImported };\n  }\n\n  \u002F**\n   * Create notebooks (with deduplication)\n   *\u002F\n  async createNotebooks(notebooks) {\n    const existing = await this.noteStore.listNotebooks();\n    const existingMap = new Map(existing.map(nb => [nb.name.toLowerCase(), nb]));\n\n    for (const nb of notebooks) {\n      const existingNb = existingMap.get(nb.name.toLowerCase());\n\n      if (existingNb) {\n        this.notebookMapping.set(nb.guid, existingNb.guid);\n      } else {\n        const newNb = new Evernote.Types.Notebook();\n        newNb.name = nb.name;\n        if (nb.stack) newNb.stack = nb.stack;\n\n        const created = await this.noteStore.createNotebook(newNb);\n        this.notebookMapping.set(nb.guid, created.guid);\n      }\n    }\n  }\n\n  \u002F**\n   * Create tags (with deduplication)\n   *\u002F\n  async createTags(tags) {\n    const existing = await this.noteStore.listTags();\n    const existingMap = new Map(existing.map(t => [t.name.toLowerCase(), t]));\n\n    for (const tag of tags) {\n      const existingTag = existingMap.get(tag.name.toLowerCase());\n\n      if (existingTag) {\n        this.tagMapping.set(tag.guid, existingTag.guid);\n      } else {\n        const newTag = new Evernote.Types.Tag();\n        newTag.name = tag.name;\n\n        const created = await this.noteStore.createTag(newTag);\n        this.tagMapping.set(tag.guid, created.guid);\n      }\n    }\n  }\n\n  \u002F**\n   * Import notebook directory\n   *\u002F\n  async importNotebook(notebookDir, notebookName, progressCallback) {\n    const notes = await fs.readdir(notebookDir, { withFileTypes: true });\n    const noteDirs = notes.filter(e => e.isDirectory());\n    let imported = 0;\n\n    for (const noteEntry of noteDirs) {\n      try {\n        const noteDir = path.join(notebookDir, noteEntry.name);\n        await this.importNote(noteDir);\n        imported++;\n\n        progressCallback?.({\n          notebook: notebookName,\n          current: imported,\n          total: noteDirs.length\n        });\n\n        \u002F\u002F Rate limiting\n        await this.sleep(200);\n\n      } catch (error) {\n        console.error(`Failed to import note ${noteEntry.name}:`, error.message);\n      }\n    }\n\n    return imported;\n  }\n\n  \u002F**\n   * Import single note\n   *\u002F\n  async importNote(noteDir) {\n    const jsonPath = path.join(noteDir, 'note.json');\n    const data = JSON.parse(await fs.readFile(jsonPath, 'utf8'));\n\n    const note = new Evernote.Types.Note();\n    note.title = data.title;\n    note.content = data.content;\n\n    \u002F\u002F Map notebook\n    if (data.notebookGuid && this.notebookMapping.has(data.notebookGuid)) {\n      note.notebookGuid = this.notebookMapping.get(data.notebookGuid);\n    }\n\n    \u002F\u002F Map tags\n    if (data.tagGuids) {\n      note.tagGuids = data.tagGuids\n        .map(guid => this.tagMapping.get(guid))\n        .filter(Boolean);\n    }\n\n    \u002F\u002F Import resources\n    if (data.resources) {\n      note.resources = [];\n      const resourcesDir = path.join(noteDir, 'resources');\n\n      for (const resMeta of data.resources) {\n        try {\n          const resource = await this.createResource(resourcesDir, resMeta);\n          if (resource) {\n            note.resources.push(resource);\n          }\n        } catch (error) {\n          console.error(`Failed to import resource:`, error.message);\n        }\n      }\n    }\n\n    return this.noteStore.createNote(note);\n  }\n\n  \u002F**\n   * Create resource from file\n   *\u002F\n  async createResource(resourcesDir, metadata) {\n    const files = await fs.readdir(resourcesDir);\n    const matchingFile = files.find(f =>\n      f.includes(metadata.hash) || f === metadata.fileName\n    );\n\n    if (!matchingFile) {\n      console.warn(`Resource file not found: ${metadata.hash}`);\n      return null;\n    }\n\n    const filePath = path.join(resourcesDir, matchingFile);\n    const fileData = await fs.readFile(filePath);\n    const hash = crypto.createHash('md5').update(fileData).digest();\n\n    const resource = new Evernote.Types.Resource();\n    resource.mime = metadata.mime;\n    resource.data = new Evernote.Types.Data();\n    resource.data.body = fileData;\n    resource.data.size = fileData.length;\n    resource.data.bodyHash = hash;\n\n    if (metadata.fileName) {\n      resource.attributes = new Evernote.Types.ResourceAttributes();\n      resource.attributes.fileName = metadata.fileName;\n    }\n\n    return resource;\n  }\n\n  sleep(ms) {\n    return new Promise(resolve => setTimeout(resolve, ms));\n  }\n}\n\nmodule.exports = EvernoteImporter;\n```\n\n### Step 4: Migration Runner\n\n```javascript\n\u002F\u002F migration\u002Frunner.js\n\nclass MigrationRunner {\n  constructor(plan, exporter, importer) {\n    this.plan = plan;\n    this.exporter = exporter;\n    this.importer = importer;\n    this.status = 'pending';\n    this.startTime = null;\n    this.endTime = null;\n    this.errors = [];\n  }\n\n  \u002F**\n   * Run migration\n   *\u002F\n  async run(progressCallback) {\n    this.status = 'running';\n    this.startTime = Date.now();\n\n    try {\n      \u002F\u002F Phase 1: Export\n      progressCallback?.({ phase: 'export', status: 'starting' });\n\n      const exportResult = await this.exporter.exportAll((progress) => {\n        progressCallback?.({ phase: 'export', ...progress });\n      });\n\n      progressCallback?.({ phase: 'export', status: 'complete', result: exportResult });\n\n      \u002F\u002F Phase 2: Import\n      progressCallback?.({ phase: 'import', status: 'starting' });\n\n      const importResult = await this.importer.importFromDirectory(\n        this.exporter.outputDir,\n        (progress) => {\n          progressCallback?.({ phase: 'import', ...progress });\n        }\n      );\n\n      progressCallback?.({ phase: 'import', status: 'complete', result: importResult });\n\n      \u002F\u002F Phase 3: Verify\n      progressCallback?.({ phase: 'verify', status: 'starting' });\n      const verifyResult = await this.verify();\n      progressCallback?.({ phase: 'verify', status: 'complete', result: verifyResult });\n\n      this.status = 'completed';\n\n    } catch (error) {\n      this.status = 'failed';\n      this.errors.push(error.message);\n      throw error;\n\n    } finally {\n      this.endTime = Date.now();\n    }\n\n    return this.getReport();\n  }\n\n  \u002F**\n   * Verify migration\n   *\u002F\n  async verify() {\n    \u002F\u002F Count notes in target\n    \u002F\u002F Compare with source count\n    \u002F\u002F Return verification status\n    return { verified: true };\n  }\n\n  \u002F**\n   * Get migration report\n   *\u002F\n  getReport() {\n    return {\n      planId: this.plan.id,\n      status: this.status,\n      startTime: new Date(this.startTime).toISOString(),\n      endTime: this.endTime ? new Date(this.endTime).toISOString() : null,\n      duration: this.endTime ? `${((this.endTime - this.startTime) \u002F 1000 \u002F 60).toFixed(1)} minutes` : null,\n      errors: this.errors\n    };\n  }\n}\n\nmodule.exports = MigrationRunner;\n```\n\n## Output\n\n- Migration planning tools\n- Evernote data exporter (JSON, Markdown, ENEX)\n- Evernote data importer\n- Migration runner with progress tracking\n- Verification and reporting\n\n## Migration Checklist\n\n```markdown\n## Pre-Migration\n- [ ] Analyze source data\n- [ ] Create migration plan\n- [ ] Backup source data\n- [ ] Test with small dataset\n- [ ] Verify API quota\n\n## During Migration\n- [ ] Monitor progress\n- [ ] Check for errors\n- [ ] Handle rate limits\n- [ ] Log all operations\n\n## Post-Migration\n- [ ] Verify data integrity\n- [ ] Compare counts\n- [ ] Test functionality\n- [ ] Document results\n- [ ] Clean up temporary files\n```\n\n## Resources\n\n- [Evernote Export Format (ENEX)](https:\u002F\u002Fdev.evernote.com\u002Fdoc\u002Farticles\u002Fenex.php)\n- [ENML Reference](https:\u002F\u002Fdev.evernote.com\u002Fdoc\u002Farticles\u002Fenml.php)\n- [API Reference](https:\u002F\u002Fdev.evernote.com\u002Fdoc\u002Freference\u002F)\n\n## Support\n\nFor complex migrations, consider contacting Evernote Business support or professional services.\n",{"name":5,"author":47,"license":15,"version":48,"description":49,"allowed-tools":50},"Jeremy Longshore \u003Cjeremy@intentsolutions.io>","1.0.0","Deep dive into Evernote data migration strategies.\nUse when migrating to\u002Ffrom Evernote, bulk data transfers,\nor complex migration scenarios.\nTrigger with phrases like \"migrate to evernote\", \"migrate from evernote\",\n\"evernote data transfer\", \"bulk evernote migration\".\n","Read, Write, Edit, Bash(npm:*), Grep","main","90b50ed0778745a80fd5bfb13b1843d45b9e82f7","tests\u002Fext_conformance\u002Fartifacts\u002Fplugins-community\u002Fplugins\u002Fsaas-packs\u002Fevernote-pack\u002Fskills\u002Fevernote-migration-deep-dive",233,"https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust","https:\u002F\u002Fgithub.com\u002FDicklesworthstone","https:\u002F\u002Fwww.jeffreyemanuel.com\u002F","Building in NY","2026-11-15 01:54:15",{"source":8,"skillName":5,"commands":61,"prompt":71,"zipAvailable":72},[62,65,68],{"tool":63,"command":64},"npx","npx skills add Dicklesworthstone\u002Fpi_agent_rust --skill evernote-migration-deep-dive",{"tool":66,"command":67},"bunx","bunx skills add Dicklesworthstone\u002Fpi_agent_rust --skill evernote-migration-deep-dive",{"tool":69,"command":70},"pnpm","pnpm dlx skills add Dicklesworthstone\u002Fpi_agent_rust --skill evernote-migration-deep-dive","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust\u002Fblob\u002Fmain\u002Ftests\u002Fext_conformance\u002Fartifacts\u002Fplugins-community\u002Fplugins\u002Fsaas-packs\u002Fevernote-pack\u002Fskills\u002Fevernote-migration-deep-dive\u002FSKILL.md",true,[],[75,103,135,154,179,203],{"skillNo":76,"name":77,"nameZh":6,"description":78,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":79,"licenseFileUrl":80,"sourceHtmlUrl":81,"categories":82,"keywords":83,"publishedAt":102},"01M6FCR7G5A005P364Z6ZWCJDP","theme-factory","Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with colors\u002Ffonts that you can apply to any artifact that has been creating, or can generate a new theme on-the-fly.","Apache-2.0","https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust\u002Fblob\u002Fmain\u002Ftests\u002Fext_conformance\u002Fartifacts\u002Ftemplates-davila7\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Fcreative-design\u002Ftheme-factory\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust\u002Fblob\u002Fmain\u002Ftests\u002Fext_conformance\u002Fartifacts\u002Ftemplates-davila7\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Fcreative-design\u002Ftheme-factory\u002FSKILL.md",[],[84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,27,100,101],"theme factory","factory","theme","docs","toolkit","generate","artifacts","SET","fly","slides","landing","html","styling","artifact","pages","themes","you","fonts","2026-11-11 15:11:14",{"skillNo":104,"name":105,"nameZh":6,"description":106,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":79,"licenseFileUrl":107,"sourceHtmlUrl":108,"categories":109,"keywords":110,"publishedAt":42},"01M6FEGPPK0ZTKCCM0R3E3KS33","web-artifacts-builder","Suite of tools for creating elaborate, multi-component claude.ai HTML artifacts using modern frontend web technologies (React, Tailwind CSS, shadcn\u002Fui). Use for complex artifacts requiring state management, routing, or shadcn\u002Fui components - not for simple single-file HTML\u002FJSX artifacts.","https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust\u002Fblob\u002Fmain\u002Ftests\u002Fext_conformance\u002Fartifacts\u002Ftemplates-davila7\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Futilities\u002Fweb-artifacts-builder\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust\u002Fblob\u002Fmain\u002Ftests\u002Fext_conformance\u002Fartifacts\u002Ftemplates-davila7\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Futilities\u002Fweb-artifacts-builder\u002FSKILL.md",[],[111,112,90,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,33,95,128,129,130,131,132,133,134],"web artifacts builder","web","artifacts builder","builder","frontend","css","components","react","component","routing","state management","state","shadcn","file","ui","Tools","Tailwind","single-file","simple","ui components","multi","for","jsx","suite",{"skillNo":136,"name":137,"nameZh":6,"description":138,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":79,"licenseFileUrl":139,"sourceHtmlUrl":140,"categories":141,"keywords":142,"publishedAt":42},"01M6FEE9VTK1W4GY21AKREJXRG","webapp-testing","Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.","https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust\u002Fblob\u002Fmain\u002Ftests\u002Fext_conformance\u002Fartifacts\u002Ftemplates-davila7\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Fsecurity\u002Fwebapp-testing\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust\u002Fblob\u002Fmain\u002Ftests\u002Fext_conformance\u002Fartifacts\u002Ftemplates-davila7\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Fsecurity\u002Fwebapp-testing\u002FSKILL.md",[],[143,144,145,115,146,147,112,148,88,149,125,150,151,152,153,27,132],"testing","webapp testing","webapp","screenshots","playwright","debugging","browser","logs","applications","behavior","local",{"skillNo":155,"name":156,"nameZh":6,"description":157,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":158,"sourceHtmlUrl":159,"categories":160,"keywords":161,"publishedAt":42},"01M6FE20F7ZTQBFWKF4MPJ2SBX","neuropixels-analysis","Neuropixels neural recording analysis. Load SpikeGLX\u002FOpenEphys data, preprocess, motion correction, Kilosort4 spike sorting, quality metrics, Allen\u002FIBL curation, AI-assisted visual analysis, for Neuropixels 1.0\u002F2.0 extracellular electrophysiology. Use when working with neural recordings, spike sorting, extracellular electrophysiology, or when the user mentions Neuropixels, SpikeGLX, Open Ephys, Kilosort, quality metrics, or unit curation.","https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust\u002Fblob\u002Fmain\u002Ftests\u002Fext_conformance\u002Fartifacts\u002Ftemplates-davila7\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Fscientific\u002Fneuropixels-analysis\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust\u002Fblob\u002Fmain\u002Ftests\u002Fext_conformance\u002Fartifacts\u002Ftemplates-davila7\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Fscientific\u002Fneuropixels-analysis\u002FSKILL.md",[],[162,163,164,165,40,166,167,168,33,169,170,171,172,173,174,175,27,176,177,178,132,25],"analysis","neuropixels analysis","spike","metrics","open","quality","user","recordings","Neural","motion","visual","quality metrics","unit","sorting","curation","recording","load",{"skillNo":180,"name":181,"nameZh":6,"description":182,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":79,"licenseFileUrl":183,"sourceHtmlUrl":184,"categories":185,"keywords":186,"publishedAt":42},"01M6FDP0PDK6F1GGX395C7625Z","skill-creator","Guide for creating effective skills. This skill should be used when users want to create a new skill (or update an existing skill) that extends Claude's capabilities with specialized knowledge, workflows, or tool integrations.","https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust\u002Fblob\u002Fmain\u002Ftests\u002Fext_conformance\u002Fartifacts\u002Ftemplates-davila7\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Fproductivity\u002Fskill-creator\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust\u002Fblob\u002Fmain\u002Ftests\u002Fext_conformance\u002Fartifacts\u002Ftemplates-davila7\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Fproductivity\u002Fskill-creator\u002FSKILL.md",[],[187,188,189,190,191,192,193,194,195,196,197,198,199,200,27,132,201,25,202],"skill creator","creator","workflows","create","update","capabilities","knowledge","tool","integrations","specialized","guide","new skill","existing skill","users","Existing","new",{"skillNo":204,"name":205,"nameZh":6,"description":206,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":207,"sourceHtmlUrl":208,"categories":209,"keywords":210,"publishedAt":42},"01M6FDM8Y7VK7NYG9SM7QPA3PW","notebooklm","Use this skill to query your Google NotebookLM notebooks directly from Claude Code for source-grounded, citation-backed answers from Gemini. Browser automation, library management, persistent auth. Drastically reduced hallucinations through document-only responses.","https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust\u002Fblob\u002Fmain\u002Ftests\u002Fext_conformance\u002Fartifacts\u002Ftemplates-davila7\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Fproductivity\u002Fnotebooklm\u002FLICENSE","https:\u002F\u002Fgithub.com\u002FDicklesworthstone\u002Fpi_agent_rust\u002Fblob\u002Fmain\u002Ftests\u002Fext_conformance\u002Fartifacts\u002Ftemplates-davila7\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Fproductivity\u002Fnotebooklm\u002FSKILL.md",[],[205,211,212,213,214,215,216,149,217,218,33,219,220,221,222,132,223],"google","browser automation","gemini","automation","auth","code","library","management","only","document","query","Citation","source"]