From b4a8cb085c51ebeade7ea66b3a52ccb2b7a7c48e Mon Sep 17 00:00:00 2001 From: Dianne Skoll Date: Fri, 22 Mar 2024 17:13:21 -0400 Subject: [PATCH] Add "blank PDF calendar" to www choices. --- www/Makefile.in | 6 ++++-- www/cal_dispatch-DIST | 4 ++++ www/calendar.html-DIST | 2 ++ www/calpdf | 11 +++++++++++ 4 files changed, 21 insertions(+), 2 deletions(-) create mode 100644 www/calpdf diff --git a/www/Makefile.in b/www/Makefile.in index a2709f60..5d22d99f 100644 --- a/www/Makefile.in +++ b/www/Makefile.in @@ -32,6 +32,7 @@ datarootdir=@datarootdir@ # Where do Remind and Rem2PS executables live? REMIND = $(bindir)/remind REM2PS = $(bindir)/rem2ps +REM2PDF = $(bindir)/rem2pdf REM2HTML = $(bindir)/rem2html # If your Web server requires CGI programs to have a .cgi suffix, use # the next line. Otherwise, comment it out @@ -46,6 +47,7 @@ SEDSCRIPT = -e 's@%CGIDIR%@$(CGIDIR)@g' \ -e 's@%REMIND%@$(REMIND)@g' \ -e 's@%IMAGEBASE%@$(IMAGEBASE)@g' \ -e 's@%REM2PS%@$(REM2PS)@g' \ + -e 's@%REM2PDF%@$(REM2PDF)@g' \ -e 's@%REM2HTML%@$(REM2HTML)@g' \ -e 's@cal_dispatch@cal_dispatch$(CGISUFFIX)@g' \ @@ -57,7 +59,7 @@ all: install: -mkdir -p $(DESTDIR)$(SCRIPTDIR) -mkdir -p $(DESTDIR)$(HTMLDIR) - cp calps hebdate hebps hebhtml moon sunrise sunset $(DESTDIR)$(SCRIPTDIR) + cp calps calpdf hebdate hebps hebhtml moon sunrise sunset $(DESTDIR)$(SCRIPTDIR) sed $(SEDSCRIPT) < cal_dispatch-DIST > $(DESTDIR)$(SCRIPTDIR)/cal_dispatch$(CGISUFFIX) sed $(SEDSCRIPT) < hebdate.rem-DIST > $(DESTDIR)$(SCRIPTDIR)/hebdate.rem sed $(SEDSCRIPT) < moon.rem-DIST > $(DESTDIR)$(SCRIPTDIR)/moon.rem @@ -73,7 +75,7 @@ install: chmod 644 $(DESTDIR)$(SCRIPTDIR)/blank.rem chmod 644 $(DESTDIR)$(HTMLDIR)/calendar.html chmod 755 $(DESTDIR)$(SCRIPTDIR)/cal_dispatch$(CGISUFFIX) - chmod 755 $(DESTDIR)$(SCRIPTDIR)/calps $(DESTDIR)$(SCRIPTDIR)/hebdate \ + chmod 755 $(DESTDIR)$(SCRIPTDIR)/calpdf $(DESTDIR)$(SCRIPTDIR)/calps $(DESTDIR)$(SCRIPTDIR)/hebdate \ $(DESTDIR)$(SCRIPTDIR)/hebps $(DESTDIR)$(SCRIPTDIR)/moon \ $(DESTDIR)$(SCRIPTDIR)/sunrise $(DESTDIR)$(SCRIPTDIR)/sunset \ $(DESTDIR)$(SCRIPTDIR)/hebhtml \ diff --git a/www/cal_dispatch-DIST b/www/cal_dispatch-DIST index 7f58bd51..d0f8b95f 100644 --- a/www/cal_dispatch-DIST +++ b/www/cal_dispatch-DIST @@ -56,6 +56,10 @@ case "$1" in exec $DIR/calps ;; + calpdf) + exec $DIR/calpdf + ;; + moon) exec $DIR/moon ;; diff --git a/www/calendar.html-DIST b/www/calendar.html-DIST index f871760c..4ce0301a 100644 --- a/www/calendar.html-DIST +++ b/www/calendar.html-DIST @@ -15,6 +15,8 @@ Sunset Information

Moon Phase Information

Blank PostScript Calendar (Approximately 20kB)

+ +Blank PDF Calendar (Approximately 15kB)

Today's Hebrew Date

diff --git a/www/calpdf b/www/calpdf new file mode 100644 index 00000000..f76b62a6 --- /dev/null +++ b/www/calpdf @@ -0,0 +1,11 @@ +#!/bin/sh +# PostScript calendar shell script +# +# This file is part of REMIND. +# Copyright (C) 1992-2018 by Dianne Skoll + +echo "Content-type: application/pdf" +echo + +$REMIND -p $DIR/blank.rem | $REM2PDF -e -c3 -l +exit 0