diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..454d6cd --- /dev/null +++ b/.travis.yml @@ -0,0 +1,17 @@ +language: node_js +node_js: + - "12.12" +cache: + directories: + - node_modules +branches: + only: + - master +before_install: + - npm update +install: + - npm ci +script: + - npm run test + - npm run coveralls + - npm run build diff --git a/CHANGELOG.md b/CHANGELOG.md index cd81f1f..cab3e57 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,14 +1,26 @@ # Changelog + All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [0.2.0] - 21-10-2019 + +### Added + +- Markdown support. +- Build command supports output folder option and args validation. +- Travis CI integration. +- Test coverage. + ## [0.1.0] - 20-10-2019 + ### Added + - Uses generic file types only. - Template system. +- Template system. - Snippet system. - Progressive builds. - CSS minification. -- Blog post, recent posts and archive. \ No newline at end of file +- Blog post, recent posts and archive. diff --git a/README.md b/README.md index c43dbd0..8cfcb20 100644 --- a/README.md +++ b/README.md @@ -1,21 +1,29 @@ +[![TravisCI](https://travis-ci.com/pirobtumen/filler.svg?branch=master)](https://travis-ci.com/pirobtumen/filler) +[![Coverage Status](https://coveralls.io/repos/github/pirobtumen/filler/badge.svg?branch=master)](https://coveralls.io/github/pirobtumen/filler?branch=master) + # Filler -1. Description -2. Features & Roadmap -3. Installation -4. Commands -5. Folder structure -6. Template system -7. Snippet system -8. Blog system -9. Contribute -10. License +Static web sites made easy. + +**Table of content** + +- [Filler](#filler) + - [Objective](#objective) + - [Features and Roadmap](#features-and-roadmap) +- [Installation](#installation) + - [Commands](#commands) + - [Folder structure](#folder-structure) + - [Template system](#template-system) + - [Snippet system](#snippet-system) + - [Blog system](#blog-system) +- [Contribute](#contribute) +- [License](#license) -## Static web sites made easy. +## Objective Filler is a tool to create a static website using templates, reusing code and saving time. Its main purpose is to be as simple as possible to use. -## Features & Roadmap +## Features and Roadmap - [x] Uses generic file types only. [v0.1.0] - [x] Template system. [v0.1.0] @@ -23,19 +31,26 @@ Filler is a tool to create a static website using templates, reusing code and sa - [x] Progressive builds (it only builds files that have changed, but you can `--force` it). [v0.1.0] - [x] CSS minification. [v0.1.0] - [x] Blog post, recent posts and archive. [v0.1.0] -- [ ] Markdown support. +- [x] Markdown support. +- [ ] Improve logging system. +- [ ] Improve error system. +- [ ] Serve project: build in memory and watch for file changes. +- [ ] Support saving into cloud storage (AWS S3, Google Cloud Storage...). +- [ ] Example templates. +- [ ] "init" command. +- [ ] Multilingual sites. - [ ] Webpack support. - [ ] React support. -- [ ] Serve project (build in memory and watch for file changes). - [ ] Server Side Rendering. - [ ] SEO features. - [ ] Any proposal? Contribute! -## Installation +# Installation -Install node [[Download link](https://nodejs.org/en/download/)] [Tested version 12.12] +Install node [[Download link](https://nodejs.org/en/download/)][tested version 12.12] Install filler: + ``` git clone https://github.com/pirobtumen/filler.git cd filler @@ -47,11 +62,12 @@ node filler --help ## Commands - build \ [OPTIONS] + - folder: project folder path. E.g.: "~/Projects/myweb". - - --force: force build all files. - - --mode [dev, prod]: build mode. Replace specifi snippets. - - --recentPosts [number]: number of recent posts rendered. - + - --output: output folder path. Default: ./dist + - --force: force build all files. Default: false + - --mode [dev, prod]: build mode. Replace specific snippets. Default: dev + - --recentPosts [number]: number of recent posts rendered. Default: 5 ## Folder structure @@ -74,13 +90,14 @@ Create the following file structure: - /styles - styles.css ``` + Build command for development: `node filler ~/Projects/myweb` Build command for production (injects analytics): -`node filler ~/Projects/myweb` +`node filler ~/Projects/myweb --mode prod` The output folder will contain: @@ -98,7 +115,7 @@ The output folder will contain: ## Template system -The files inside the public folder can use any template created inside the `/templates` folder. The idea is to set the property `@template