Page 1 of 3

Import posts from existing blog?

Posted: Sun Jun 03, 2018 1:22 am
by donblanco
I have a 2nd blog I want to convert to bludit - the images are in one folder, the posts are in another folder (in markdown format). Is there an import plugin I could use to create posts from the markdown files?

Re: Import posts from existing blog?

Posted: Sun Jun 03, 2018 1:50 am
by Edi
What system is used for the second blog?

Re: Import posts from existing blog?

Posted: Sun Jun 03, 2018 1:57 am
by donblanco
it's hosted on Github Pages - I *think* I generated it with Hugo, but it's been awhile so I am not certain.

Re: Import posts from existing blog?

Posted: Sun Jun 03, 2018 3:41 pm
by diego
As far I know there is not a plugin for such thing.

Bludit support markdown files but has his own structure for the title and other fields.

Here you have the content of the blog of Bludit. https://blog.bludit.com
https://github.com/bludit/blog

and the structure is:
https://raw.githubusercontent.com/bludi ... 0/index.md

if you want to use the extension to ".md" you need to change here :
https://github.com/bludit/bludit/blob/m ... es.php#L60

Regards

Re: Import posts from existing blog?

Posted: Sun Jun 03, 2018 3:57 pm
by donblanco
right now all posts are in .md format - each post is an individual markdown file using some YML at the top - here is an example:

Code: Select all

---
id: 4036
title: The Legend of Johnny Vagabond
author: Glenn
layout: article
permalink: /legend-johnny-vagabond/
dsq_thread_id:

  - 3268641043
categories:

  - News
image:

  feature: johnny-vagabond.jpg

  teaser: johnny-vagabond.jpg
comments: true
---
We first met [Wes Nations][1] our second night in San Cristóbal de las Casas, Chiapas, after [Jon Look][2] introduced us. We met at a wine bar, of course. (etc., etc.) 
I was hoping to come up with a way to use the API to run a command and convert all MD files to Bludit posts, but I'm not that good of a programmer. I may have to do some search/replace and strip the YAML then manually copy/paste each post, as well put all images into an image folder...

Re: Import posts from existing blog?

Posted: Sun Jun 03, 2018 4:05 pm
by Edi
It seems, that there is a mixture of Markdown and YAML.

Is it possible to export all posts?

Perhaps you can use some code from the WordPress to Bludit Converter:

https://plugins.bludit.com/plugin/wordpress-to-bludit

Re: Import posts from existing blog?

Posted: Sun Jun 03, 2018 6:37 pm
by donblanco
Now that you mention it, I think I can export from Hugo/Github into WordPress - then use the WP>Bludit converter. Thanks!

Re: Import posts from existing blog?

Posted: Wed Jun 06, 2018 11:46 pm
by donblanco
So there does not seem to be an easy way to do this. I have a folder full of markdown files and I don't think I will be able to use Bludit for this site. :(

Re: Import posts from existing blog?

Posted: Thu Jun 07, 2018 12:57 am
by Edi
Is there a tool for exporting the content? Or how have you done it?

Re: Import posts from existing blog?

Posted: Thu Jun 07, 2018 3:58 pm
by donblanco
These files are from a previous Hugo > Github Pages install. Hugo does a static site generation thing. I am wanting to either automate the import into Bludit, or find a blog software that will utilize the files as they are. I'm beginning to think I am out of luck on all fronts. :(