A simple PDF calender generator written in go


First you must compile this program by running make or go build. Then you will have a new program called gcalgen. If you simply run ./gcalgen you will have a new pdf in your current working directory which is a pdf calender for the current year that is set on your computer. If your computer says the current year is 2022, then your will now have a pdf calender for 2022.

Run ./gcalgen -h to get a listing of all posssible command parameters. Here are some examples:

  • ./gcalgen -y 2077 will generate a calendar for the year 2077
  • ./gcalgen -y 2077 -o 2077-cal.pdf will generate a calendar for the year 2077 called 2077-cal.pdf
  • ./gcalgen -ical myical.ics will generate a calendar for the year set on your computer and it will output a list of holidays on the last page of the pdf.
  • ./gcalgen -po P -pt A5 will generate a calendar that is in portrait orientation that fit on an A5 paper.

In the tools directory there are tools that help with gcalgen. Currently there is only one tool and that is icaledit. Just run make or go build in the icaledit directory and run ./icaledit and follow the instructions to construct a new ical file that can be used with gcalgen. Inside the icaledit directory there is also a file called file and a bash script. the bash script just pipes the contents of file to icaledit to avoid having to manually type in all the events.


You can find releases of gcalgen and its tools here. Currently there is only one extra tool for gcalgen and that is icaledit, therefore only two binaries need to be downloaded. If you are on 64-bit windows, then download gcalgen_windowsamd64.exe and icaledit_windowsamd64.exe. If you are on linux then download the two appropriate binaries. The same goes for any other operating system and architecture. There are binaries for windows, linux, darwin(MacOS), plan9, openbsd, netbsd, freebsd and dragonflybsd.


View Github