huangbowen521 / octopress-syncPost

A octopress plugin to sync the latest post to a website which suport MetaWeblog. etc Wordpress, CSDN, CNBlogs,BlogBus....

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

published=false is ignored.

nielinjie opened this issue · comments

Articles have marked 'published=false' is post. Which is not cool.

Sorry, I'm not so clear with it. Where is the "published" attribute?
Could you please make it more clear to help us fix the bug? Thanks a lot =)

I got it, thanks.

Hi nielinjie,
I also have articles marked as "published=false", but I cannot reproduce the bug when I run rake sync_all_posts.
Did you have the same problem after you ran rake generate? Did the unpublished articles appear in public/archives/index.html?
Thanks.

  • I find this issue when I run sync_latest_post, not sync_all_posts
  • I used not to run rake generate, only preview-develop loop. Does this matter somthing?
  • I can not find public/archives... folder, but if you mean public/blog/archives.... folder, yes, they dose appear.

Hi nielinjie,
First of all, thank you for your feedback and clarification, which makes the issue much more clear.
Secondly, I cannot reproduce the bug by running rake sync_latest_post, either.
Correct me if I am wrong, but I think the problem may be caused by not running rake generate. As far as I know from the source code, the plugin reads the list of published articles from the public/blog/archives/index.html (sorry I put a wrong path in my last post) or public/index.html. To obtain the correct list, these two files need be updated to remove the unpublished articles. And one way to update these files is to regenerate them by rake generate. That's why the README asks the users to run rake generate before they synchronize the post.