2025-01-27 09:30:28 -05:00
|
|
|
import * as inquirer from '@inquirer/prompts';
|
|
|
|
|
|
|
|
|
|
export const all = [
|
|
|
|
|
{
|
|
|
|
|
name: 'wizard',
|
|
|
|
|
type: 'boolean',
|
|
|
|
|
description: 'Use wizard',
|
|
|
|
|
default: true
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: 'input',
|
|
|
|
|
type: 'file-path',
|
|
|
|
|
description: 'Path to WordPress export file',
|
|
|
|
|
default: 'export.xml',
|
|
|
|
|
prompt: inquirer.input
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: 'post-folders',
|
|
|
|
|
type: 'boolean',
|
|
|
|
|
description: 'Put each post into its own folder',
|
|
|
|
|
default: true,
|
|
|
|
|
choices: [
|
|
|
|
|
{
|
|
|
|
|
name: 'Yes',
|
2025-01-27 14:57:04 -05:00
|
|
|
value: true
|
2025-01-27 09:30:28 -05:00
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: 'No',
|
2025-01-27 14:57:04 -05:00
|
|
|
value: false
|
2025-01-27 09:30:28 -05:00
|
|
|
}
|
|
|
|
|
],
|
2025-01-27 17:12:17 -05:00
|
|
|
isPathQuestion: true,
|
2025-01-27 09:30:28 -05:00
|
|
|
prompt: inquirer.select
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: 'prefix-date',
|
|
|
|
|
type: 'boolean',
|
|
|
|
|
description: 'Prefix with date',
|
|
|
|
|
default: false,
|
|
|
|
|
choices: [
|
|
|
|
|
{
|
|
|
|
|
name: 'Yes',
|
2025-01-27 14:57:04 -05:00
|
|
|
value: true
|
2025-01-27 09:30:28 -05:00
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: 'No',
|
2025-01-27 14:57:04 -05:00
|
|
|
value: false
|
2025-01-27 09:30:28 -05:00
|
|
|
}
|
|
|
|
|
],
|
2025-01-27 17:12:17 -05:00
|
|
|
isPathQuestion: true,
|
2025-01-27 09:30:28 -05:00
|
|
|
prompt: inquirer.select
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: 'date-folders',
|
|
|
|
|
type: 'choice',
|
|
|
|
|
description: 'Organize into folders based on date',
|
|
|
|
|
default: 'none',
|
|
|
|
|
choices: [
|
|
|
|
|
{
|
|
|
|
|
name: 'Year folders',
|
2025-01-27 14:57:04 -05:00
|
|
|
value: 'year'
|
2025-01-27 09:30:28 -05:00
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: 'Year and month folders',
|
2025-01-27 14:57:04 -05:00
|
|
|
value: 'year-month'
|
2025-01-27 09:30:28 -05:00
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: 'No',
|
2025-01-27 14:57:04 -05:00
|
|
|
value: 'none'
|
2025-01-27 09:30:28 -05:00
|
|
|
}
|
|
|
|
|
],
|
2025-01-27 17:12:17 -05:00
|
|
|
isPathQuestion: true,
|
2025-01-27 09:30:28 -05:00
|
|
|
prompt: inquirer.select
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: 'save-images',
|
|
|
|
|
type: 'choice',
|
|
|
|
|
description: 'Save images',
|
|
|
|
|
default: 'all',
|
|
|
|
|
choices: [
|
|
|
|
|
{
|
|
|
|
|
name: 'Images attached to posts',
|
|
|
|
|
value: 'attached'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: 'Images scraped from post body content',
|
|
|
|
|
value: 'scraped'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: 'Both',
|
|
|
|
|
value: 'all'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: 'No',
|
|
|
|
|
value: 'none'
|
|
|
|
|
}
|
|
|
|
|
],
|
|
|
|
|
prompt: inquirer.select
|
|
|
|
|
}
|
|
|
|
|
];
|