Skip to content

Add function to add current date to file name #12

@anthonyokc

Description

@anthonyokc

E.g. write_csv(parties, here(stamp_date("data/output/parties.csv")))

If today's date were 2025-03-17 would write the file to "[project root]/data/output/2025_03_17_parties.csv"

Robust to if user puts

  • write_csv(parties, here(stamp_date("data/output/parties.csv")))
  • write_csv(parties, stamp_date(here("data/output/parties.csv")))
  • write_csv(parties, here("data/output/", stamp_date(parties.csv")))

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions