Skip to content

linychuo/my-blog

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

my personal blog generator

  • pure static blog using rust
  • please visit site Yongchao.Li, welcome push a issue if you found any problem, Thanks!

Overview

This project was built with Rust language, rust has lots of features. no garbage collection(GC), no runtime overhead, and ensures safety, among other features. all content is placed in the 'post' directory, they were written by markdown. and the template engine uses Handlerbars for Rust. any person could fork this project and build their own blog site.

Code structure

  • src
    • main.rs
      main entry point of the program, it parses params from command line and generates HTML files, copy static files, this comnand line must be contained five constants
      • posts_dir: path name for original content of each post
      • static_files_dir: path name for static files
      • templates_dir: path name for template files
      • build_dir: path name for final building
      • excludes: excludes file list while program starts generating html files
    • blogger.rs
      it representes a blogger object, it has a few methods, render all posts, index page and copy static files
    • post.rs
      it was represented a article object and behaviors
  • posts contains all the original posts
  • static includes all static resources, it includes css, js, images
  • templates kinds of template file

About

my personal blog by rustlang

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •