Skip to content

atao60/pop-tech

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pop Tech

A blog with static pages generated by jbake and hosted on Github.

Implementation

jbake is a great framework, it lets you free to choose your tools for the:

This project is based on Y. Bonnel's blog, hosted here. The main changes from it are:

  • Use maven-scm-publish-plugin in place of Github Site Plugin: it works even if the Github user profile is not fully filled, see Pourquoi ce blog ? (in french).

  • Generate excerpts for the index and feed pages: it requires a helper class (in Xtend) and some scripts (in Groovy) inside the templates. Then no needs to fork jbake or jbake-maven-plugin.

  • Share parameters between Maven and jbake-maven-plugin, with a little trick: properties-maven-plugin is used to generate a file custom.properties (which usage is deprecated by jbake) filled with all the Maven properties.

There is an open request on this topic: adding system and pom properties to config object in templates #9 .

  • Update assets with Maven, using webjars: the Maven profile webjars will upgrade the libraries.

  • Enforce the most recent libraries and plugin: the Maven profile enforce will do all the checking.

  • Misc. (i18n, tag counters, escaped rss titles, ...)

Todo

  • i18n: to be able to publish the same post in different languages.
  • merge storing on Github with publishing using Travis.
  • no more XML: Logback is already configurated with Groovy, now Polyglot for Maven can work with Groovy also.

Requirements

Java 8 is required by the pom. But Java 7 should still work.

Maven 3.3.1 or above is required as Maven profiles are managed with maven-profiledep-extension. Still Maven 3.3 or below can be used: all the chained profiles must be specified on the command line, e.g. "-Pbootswatch-pathes -Pminify -Pwebjars" in place of "-Pwebjars".

Display

To see the blog, go on Github gh-pages or on popsuite.

Edit

The posts are stored under src/jbake/content.

They can be written with any of these formats: Markdown, AsciiDoc and HTML.

The jbake documentation is available here.

Build and running

  • To update the assets (Bootswatch, SyntaxHighlighter, ...):
    mvn clean process-resources -Pwebjars
     
    With M2Eclipse, see launcher pop-tech_setup_webjars.

  • To get excerpt enhancement, popsuite-blog:pop-tech itself must have been installed in the local m2 repository, otherwise do it now:
    mvn clean install
     
    With M2Eclipse, see launcher pop-tech_clean_install.

  • To preview the changes:
    mvn clean process-resources jbake:inline
    and go to http://localhost:8083.
     
    With M2Eclipse, see launcher pop-tech_clean_generate_inline.

The port is defined by "jbake.port" in the pom file.

  • Before publishing, save the changes on Github.

  • To publish the changes:
    mvn clean jbake:generate scm-publish:publish-scm  
    With M2Eclipse, see launcher pop-tech_clean_generate_publish.

References

Credits, licenses, copyright

About

A blog generated with jbake and hosted by Github

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published