From b3b3a6c6908fdc53422501e9d5755f1af277bb4f Mon Sep 17 00:00:00 2001 From: Ananth Venkatesh Date: Wed, 4 Feb 2026 20:01:54 -0500 Subject: [PATCH 1/2] feat: allow specifying date format most templates allow this --- pset.typ | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pset.typ b/pset.typ index 8cf5ef8..11c870e 100644 --- a/pset.typ +++ b/pset.typ @@ -3,6 +3,7 @@ title: "PSET 0", student: "Alyssa P. Hacker", date: datetime.today(), + date-format: "[month repr:long] [day padding:none], [year]", subproblems: "1.1.a.i", collaborators: (), doc, @@ -60,7 +61,7 @@ text(size: 1.6em, weight: "bold")[#class -- #title \ ] text(size: 1.2em, weight: "semibold")[#student \ ] emph[ - #date.display("[year]-[month]-[day]") + #date.display(date-format) #if collaborators != none { [ \ Collaborators: #collaborators From 510711999c88ad95a3639aca4163db0902362f1e Mon Sep 17 00:00:00 2001 From: Ananth Venkatesh Date: Wed, 4 Feb 2026 20:05:29 -0500 Subject: [PATCH 2/2] docs: add `date-format` argument to readme --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index f9da4f6..a2253ad 100644 --- a/README.md +++ b/README.md @@ -19,5 +19,6 @@ The `pset` function takes the following named arguments: - `student` (string): Student completing the assignment. - `title` (string): Title of the assignment. - `date` (datetime): Date to be displayed on the assignment. +- `date-format` (string): Date format string to use for displaying `date` (see [Typst docs](https://typst.app/docs/reference/foundations/datetime/) for formatting instructions) - `collaborators` (array of strings): Collaborators that worked on the assignment with the student. Can be `()`. - `subproblems` (string): Numbering scheme for the subproblems.