blob: 5a331d474bd51da3c400878ce7422d959d0f213b (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
.Dd February 12, 2026
.Dt BOLT-DOWN 1
.Os
.Sh NAME
.Nm bolt-down
.Nd revert migrations against the database
.Sh SYNOPSIS
.Nm bolt down
.Op Fl v Ar version
.Op Fl -version Ar version
.Sh DESCRIPTION
.Nm
reverts applied migrations from the database. Migrations are reverted in
reverse dependency order.
.Pp
By default, all applied migrations are reverted. Use the
.Fl v
option to revert migrations down to and including a specific version.
.Pp
Each migration runs within a transaction by default, ensuring that if any
statement fails, the entire revert is rolled back. See
.Xr bolt-execution 7
for details on transaction behavior.
.Sh OPTIONS
.Bl -tag -width Ds
.It Fl v Ar version , Fl -version Ar version
Revert migrations down to and including the specified version.
.El
.Sh EXIT STATUS
.Nm
exits 0 on success, and >0 if an error occurs.
.Sh EXAMPLES
Revert all applied migrations:
.Dl $ bolt down
.Pp
Revert migrations down to a specific version:
.Dl $ bolt down -v 20240316145038
.Sh SEE ALSO
.Xr bolt 1 ,
.Xr bolt-status 1 ,
.Xr bolt-up 1 ,
.Xr bolt-execution 7
|