Code Monkey home page Code Monkey logo

writebook's Introduction

forthebadge made-with-python MIT license

writeBook

Automatically copies and pastes a .docx file from a template document that contains all the industry standards for book manuscripts. This eliminates the hassle of setting up the document and working environment before writing a book.

This is only tested for the Windows OS.

Command

book <name of your book>

Preparations

Download templates here: https://kdp.amazon.com/en_US/help/topic/G201834230, create a 'Templates' folder, open the downloaded file and choose a language of your choice. Then, copy and paste all the .docx files into 'Templates'. I choose to do it this way rather than committing the template files themselves because I'm not sure if I'm legally allowed to republish Amazon KDP's content.

Alternatively, you can create your own .docx template with your own preferences and styles.

Set up working environment

py -m venv <name of your venv>
cd <name of your venv>
git clone https://github.com/johncmanuel/writeBook.git
pip install requirements.txt

Run venv

cd Scripts && activate.bat && cd ..

Environment Variables

In your local machine, add working environment to 'Path'.

In the working directory, create an .env file and add the following variables:

# .env

BOOK_DIR=<path to where you want to place your writing documents>
TEMPLATES_DIR=<path to your templates folder>
PATH_TO_WORD=<path to your Microsoft Word application>

*However, PATH_TO_WORD can be used for any other writing software.

writebook's People

Contributors

johncmanuel avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.