Skip to content

Commit

Permalink
add some utility scripts for making tasks for reading books
Browse files Browse the repository at this point in the history
  • Loading branch information
BrianHicks committed Dec 31, 2018
1 parent f37b779 commit 93e8d0c
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
13 changes: 13 additions & 0 deletions chapters.py
@@ -0,0 +1,13 @@
#!/usr/bin/env python
from __future__ import print_function, unicode_literals
import sys

task_templates = [
"read {}",
"make chapter summary for {}",
"make flashcards for {}",
]

for line in sys.stdin.readlines():
for template in task_templates:
print(template.format(line.strip()))
2 changes: 2 additions & 0 deletions chapters.sh
@@ -0,0 +1,2 @@
#!/usr/bin/env bash
seq 1 ${1} | tr ' ' '\n' | sed -E 's/^/chapter /g' | python chapters.py

0 comments on commit 93e8d0c

Please sign in to comment.