• Stars
    star
    125
  • Rank 286,335 (Top 6 %)
  • Language
    Python
  • License
    Apache License 2.0
  • Created about 7 years ago
  • Updated 7 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Generate a personalized life calendar poster

Personalised Life Calendar Generator

I'm a fan of the Life Calendars that can be found on Tim Urban's website www.waitbutwhy.com. It's basically a calendar for your whole life on a single poster, with a single box representing a week, a single row represrenting a year (52 boxes), and 90 rows for a total of 90 years.

I liked having it on my wall, and for a while I tried using it to mark significant past events, as well as future goals & plans. There are a couple of practical problems with this, however, because of the current design of the Life Calendars. The main problem is that there are no real date references on the poster, unless you write them in yourself, so honing in on a specific box (say, the week you're currently in right now) is tedious and error-prone.

The reason for this is obvious; the dates shown would be specific to your own birthday, so you can't make one poster for everybody if there are dates on it. The minimalist design of the poster kind of compensates for this, since you are left with plenty of room to write/draw whatever you want. Fair enough.

I'm lazy, though. I don't want to write all those dates in. Plus, if I lose or damage the poster, I'd have to do all that work again. So I did this instead.

This script takes your birthday as an argument, and generates a .pdf file containing a life calendar annotated with your personal dates. (Document size is 29x40 inches, for best printing results)

Several additional features make navigation through the calendar a bit easier;

  1. Rather than just starting exactly on your birthday, it starts on the last Monday before your birthday (i.e. the first day of the week you were born). This makes it much easier to identify which box holds a particular date, since every box starts with a Monday and represents "the week starting on <date>"
  2. For each row, the date of the first day of the first box in the row is printed on the right hand side. This date is always a Monday, as explained in #1.
  3. Boxes containing your birthday are shaded
  4. Boxes containing the first day of the year are shaded (a different shade)
  5. Number of calendar rows (years) is configurable between 90-100

Installation

Dependencies

You must install pycairo before you can generate a Life Calendar:

  • PyCairo (Python library for drawing stuff & generating documents/images)

    pip install pycairo
    

    Or if you're running something like Debian/Ubuntu:

    sudo apt-get install python-cairo
    

If you are getting Error: out of memory when running pycairo on windows after installing with pip, try instead installing from this archive of pre-built pycairo wheels for windows. Make sure to pick the right wheel for your system, i.e. if you are using 64-bit python 3.11, you should pick pycairo-1.21.0-cp311-cp311-win_amd64.whl.

Download

Clone this repo to get the generate_life_calendar.py script

$> git clone https://github.com/eriknyquist/generate_life_calendar

Usage

After cloning this repo, run the script, passing in your birth date (format can be either dd-mm-yyyy or dd/mm/yyyy)

$> cd generate_life_calendar
$> python generate_life_calendar.py "23/10/1990"

Created life_calendar.pdf

By default, the output will be a file called life_calendar.pdf. You can change the output filename with the -f option

$> python generate_life_calendar.py "23/10/1990" -f my_life_calendar.pdf

Created my_life_calendar.pdf

If you would like to fill in the squares for past weeks but don't want to do this by hand, just pass the -d option to darken past weeks

$> python generate_life_calendar.py "23/10/1990" -d

Created life_calendar.pdf

More Repositories

1

duckargs

Code generation tool, creates python / C programs that parse command line arguments. Say bye to starting each project by reading "argparse" / "geptopt.h" docs.
Python
110
star
2

librxvm

non-backtracking NFA-based regular expression library, for C and Python
C
61
star
3

boyermoore

Boyer-moore in pure python, search for unicode strings in large files quickly
Python
20
star
4

tones

Pure-python library for generating audio tones, with support for polyphony, pitch-bending and vibrato
Python
17
star
5

ptttl

Polyphonic Tone Transfer Language: superset of NOKIA's RTTTL, supports polyphony & vibrato
C
14
star
6

text_game_maker

Python framework for creating text-based games (interactive fiction)
Python
12
star
7

personal-site

HTML
11
star
8

nedry

Nedry is a fun & useful discord bot with a modular plugin system (formerly "twitch_monitor_discord_bot")
Python
10
star
9

deep_space_trader

Deep Space Trader is a turn-based strategy game inspired by the old DOS game "Drugwars".
Python
9
star
10

versionedobj

Easy object serialization and versioning framework for python
Python
9
star
11

BrainfuckIntern

Uses a genetic algorithm to "evolve" brainfuck programs with desirable behaviours
C
9
star
12

app_timer

Friendly, lightweight, hardware-agnostic timer abstraction layer in C. Use a single timer/counter source to drive many timed events.
C
8
star
13

bfi

Fast optimizing Brainfuck interpreter in pure python
Brainfuck
8
star
14

chatbot_utils

RegEx-based fuzzy command / response handling for conversational chatbots
Python
4
star
15

keystroke_transcriber

Records global keypress events and translates them into a program that replays those keypress events on some programmable USB HID device (e.g. Digispark)
Python
3
star
16

wikichangewatcher

Python library for easy monitoring of all Wikipedia page edits
Python
3
star
17

hashtable

A lightweight separate-chaining arena-backed hashtable in C, designed to be flexible enough for embedded systems
C
3
star
18

ulist

Unrolled linked list implementation in C
C++
2
star
19

parse_args

Portable command-line argument parser for C programs
C
2
star
20

cheaders

C header file generator
Python
2
star
21

zombiegame

C#
1
star
22

trivia_discord_bot

A discord bot for group trivia contests
Python
1
star
23

addlad

A single-instruction esoteric programming language, inspired by Chris Domas' "MovFuscator"
Python
1
star
24

varints

Variable-length integer (VLQ) encoding and decoding, in C99. https://en.wikipedia.org/wiki/Variable-length_quantity
C
1
star
25

arduinozero-metronome

Stage metronome for drummers, using Arduino Zero
C
1
star
26

twitch_talkbot

Python
1
star
27

snakeng

Implementation of the classic "snake" game as a re-usable engine. Play snake on the command line, or implement your own!
Python
1
star
28

google_drive_files

Download/list files from Google Drive by filename
Python
1
star
29

versioned_config

Python library for creating and managing versioned configuration files
Python
1
star
30

chatbot_builder

A discord chat bot that is programmed interactively by discord users
Python
1
star
31

ArduinoSoftwarePinInterrupts

This arduino library implements a software-polling-based version of the "attachInterrupt" function, which supports all digital pins on all hardware types, supports attaching multiple handlers to a single pin, and also has built-in optional debouncing for your input signals.
C++
1
star