An unofficial Bible-reading-plan generator
git clone git://git.danielmoch.com/cbr-schedule.git
Log | Files | Refs | README | LICENSE

commit 12800fa7749e2c8876ff4fa4760913cefa9d32fe
parent 4e02e4fffc511f03f512601f4c217991a386a1e7
Author: Daniel Moch <daniel@danielmoch.com>
Date:   Sun, 25 Feb 2018 07:35:44 -0500

Add Makefile.

Ready for merge to master

AMakefile | 37+++++++++++++++++++++++++++++++++++++
MREADME.md | 14++------------
2 files changed, 39 insertions(+), 12 deletions(-)

diff --git a/Makefile b/Makefile @@ -0,0 +1,37 @@ +# +# The MIT License (MIT) +# +# Copyright (c) 2018 Daniel Moch +# +# Permission is hereby granted, free of charge, to any person obtaining a copy +# of this software and associated documentation files (the "Software"), to deal +# in the Software without restriction, including without limitation the rights +# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +# copies of the Software, and to permit persons to whom the Software is +# furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included in all +# copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +# SOFTWARE. +# +SECTIONS=sections/new_testament.json sections/old_testament.json sections/psalms.json + +text: $(SECTIONS) + ./generate_schedule output.txt + +json: $(SECTIONS) + ./generate_schedule output.json + +clean: + rm output.* + rm sections/*.json + +sections/%.json: sections/%.in + ./generate_readings $< diff --git a/README.md b/README.md @@ -23,18 +23,8 @@ Other export formats on the roadmap: # Usage -A Makefile would be nice, I'll get one of those up soon too. In the -meantime, the process will be a bit manual. Take the following example: - -``` -./generate_readings sections/old_testament.in -./generate_readings sections/new_testament.in -./generate_readings sections/psalms.in -./generate_schedule output.txt -``` - -The final result of these commands would be a file called `output.txt` -that contains a formatted text file with the 2018 CBR schedule. +1. `make text` builds a formatted text file (also built with simply `make`) +2. `make json` builds a JSON file # License