Skip to content
Documentation GitHub
Content

Import System

Status: Implemented Depends On: Workspace System, Page System, User Settings


The Import System enables users to bring existing content into Inklings from external sources. It supports markdown folders and Obsidian vaults.

Import copies files into the workspace. Original files remain untouched. This is:

  • Safe: No risk of data loss
  • Reversible: Can re-import if needed
  • Clear: User knows where their content lives

Hierarchy is preserved exactly as-is with no depth limit. Deep nesting (5+ levels) triggers an informational warning in the preview, but does NOT prevent or modify the import:

Source (6 levels): Imported (identical):
world/ world/
└── regions/ └── regions/
└── countries/ └── countries/
└── cities/ └── cities/
└── districts/ └── districts/
└── blocks/ └── blocks/

Note: The informational warning helps users understand their content organization but respects the original structure.

Obsidian-style [[wiki links]] converted to standard markdown:

  • [[Page Name]] -> [Page Name](./page-name.md)
  • [[Page Name|Display]] -> [Display](./page-name.md)

Users see what is imported before it happens:

  • File count
  • Structure preview
  • Potential issues (deep nesting, conflicts)
  • Estimated time for large imports

Direct import of any folder containing .md files:

  • Recursively scan for .md files
  • Preserve relative structure
  • Copy frontmatter as-is
  • Generate IDs for pages without them

Specialized handling for Obsidian vaults:

  • Convert [[wiki links]] to standard links
  • Handle ![[embeds]] (convert to links or inline)
  • Map Obsidian frontmatter to Inklings format
  • Ignore .obsidian/ config folder
1. Select Source
└── User picks folder or Obsidian vault
2. Analyze
└── Scan files, detect issues, build preview
3. Preview
└── Show what is imported
└── Highlight issues (deep nesting, conflicts)
4. Configure (optional)
└── Rename conflicting pages
└── Choose flatten strategy
5. Import
└── Copy files with progress indicator
└── Convert links
└── Generate index
6. Complete
└── Show summary
└── Highlight any warnings
+-------------------------------------------------------------+
| Import Preview |
+-------------------------------------------------------------+
| Source: /Users/user/Obsidian/My Vault |
| Type: Obsidian Vault |
| |
| Files to import: 127 |
| Folders: 15 |
| |
| i 3 folders are deeply nested (5+ levels) |
| ! 2 files have name conflicts |
| |
| Preview: |
| +-- characters/ (24 files) |
| +-- locations/ (18 files) |
| +-- factions/ (12 files) |
| +-- ... 73 more files |
| |
| [Cancel] [Start Import] |
+-------------------------------------------------------------+
// Analyze source for import preview
analyze_import(path: string): Promise<ImportAnalysis>
// Execute import
execute_import(params: ImportParams): Promise<ImportResult>
// Get import progress (for large imports)
get_import_progress(): Promise<ImportProgress>
// Cancel in-progress import
cancel_import(): Promise<void>
interface ImportAnalysis {
source_type: 'markdown' | 'obsidian';
file_count: number;
folder_count: number;
issues: ImportIssue[];
preview: FolderPreview;
}
interface ImportIssue {
type: 'deep_nesting' | 'name_conflict' | 'invalid_frontmatter';
path: string;
message: string;
suggestion: string;
}
interface ImportParams {
source_path: string;
destination_path?: string; // Default: workspace root
flatten_strategy: 'preserve' | 'flatten_deep';
conflict_strategy: 'skip' | 'rename' | 'overwrite';
}
interface ImportResult {
imported_count: number;
skipped_count: number;
warnings: string[];
}
interface ImportProgress {
total: number;
completed: number;
current_file: string;
phase: 'analyzing' | 'copying' | 'converting' | 'indexing';
}
ObsidianStandard Markdown
[[Page]][Page](./page.md)
[[Page|Display]][Display](./page.md)
[[Folder/Page]][Page](./folder/page.md)
![[Embed]][Embed](./embed.md) (or inline)
[[#Heading]][Heading](#heading)

Links are resolved relative to the page containing them:

  • Same folder: ./sibling.md
  • Child folder: ./child/page.md
  • Parent folder: ../sibling.md
ErrorHandling
Unreadable fileSkip, add to warnings
Invalid frontmatterImport as plain markdown
Circular linksConvert to plain text
Disk fullStop import, show error, keep partial
  • Unit: Link conversion, path resolution
  • Application: Import analysis, conflict detection
  • Infrastructure: File operations with temp directories
  • E2E: Full import flow with sample vault

This is a “capstone” feature that proves the whole system works together.

Was this page helpful?