SkillAgentSearch skills...

Pgtt

pgtt is a time traveling tool for PostgreSQL to help speedup development and testing of various applications by enabling the user to easily travel between points in time. This can be useful when for example you have to test a certain mutation multiple times and want to quickly rollback to before the mutation to make changes to the behaviour and test again. This will save time and avoids setting up the data over and over again, especially in larger applications with complex data and flows.

Install / Use

/learn @BenjaminFaal/Pgtt

README

pgtt

pgtt is a time traveling tool for PostgreSQL to help speedup development and testing of various applications by enabling the user to easily travel between points in time. This can be useful when for example you have to test a certain mutation multiple times and want to quickly rollback to before the mutation to make changes to the behaviour and test again. This will save time and avoids setting up the data over and over again, especially in larger applications with complex data and flows.

databases screenshot info snapshot

How it works

PostgreSQL supports creating databases with a TEMPLATE. pgtt utilises this to create a copy of a database. Once the user wants to time travel to a specific copy pgtt simply replaces the current database with the copy.

PostgreSQL enforces there are no active connections to the database when copying or restoring. pgtt will simply terminate all connections to that database before these actions. This can result in your application crashing or not being able to connect to the database while copying.

Usage

Docker image

Use the docker-compose.yml for a good starting point to see how to configure and use pgtt.

Development

  1. Setup a PostgreSQL database
  2. Setup the .env file accordingly
  3. npm install
  4. npm run dev

Related Skills

View on GitHub
GitHub Stars45
CategoryDevelopment
Updated3mo ago
Forks1

Languages

Svelte

Security Score

95/100

Audited on Jan 3, 2026

No findings