aboutsummaryrefslogtreecommitdiffstats
path: root/CHANGELOG.md
blob: 3f843d528367ec2db1ae56da9f101bf418dbbbf6 (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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.8.2] - 2024-03-23

### Added

- No code changes. New release is being created to be able to trigger a Github Action to release pre-compiled binaries with the release.

## [0.8.1] - 2024-03-23

### Fixed

- If a local migration with the same version already exists, bolt will now error out when listing out the migrations and indicate that there is a conflicting migration. Previously, it would ignore the first migration and use the second one with the same version.

## [0.8.0] - 2024-03-16

### Changed

- Migrations are now a single file with an upgrade and downgrade script delineated by a `-- migrate:up` or `--migrate:down` comment instead of the prior approach where the migration was a directory with a `upgrade.sql` and `downgrade.sql` file within it.

- Default version style is now timestamp.

- `bolt_migrations` `version` column is now a `VARCHAR(255)` instead of `CHARACTER(14)`.

## [0.7.0] - 2024-03-14

### Changed

- Renamed the following environment variables names:
  - `BOLT_DB_CONN_HOST` -> `BOLT_DB_HOST`
  - `BOLT_DB_CONN_PORT` -> `BOLT_DB_PORT`
  - `BOLT_DB_CONN_USER` -> `BOLT_DB_USER`
  - `BOLT_DB_CONN_PASSWORD` -> `BOLT_DB_PASSWORD`
  - `BOLT_DB_CONN_DBNAME` -> `BOLT_DB_NAME`
  - `BOLT_DB_CONN_DRIVER` -> `BOLT_DB_DRIVER`

- Renamed the `[connection]` section of `bolt.toml` to `[database]`.

### Fixed

- Panic that occurs when `bolt new` is run without a remote database connection setup.

## [0.6.0] - 2024-03-11

### Added

- Support for Microsoft SQL Server.
- Support for SQLite3.

### Changed

- Default the version style to sequential.

## [0.5.0] - 2024-03-10

### Added

- Support for MySQL.

### Changed

- The "postgres" driver name is now called "postgresql".

## [0.4.0] - 2024-03-09

### Changed

- Replaced the lib/pq postgres driver with pgx.

## [0.3.0] - 2024-03-02

### Added

- Documentation on `bolt version` command.
- Ability to use sequentially versioned or timestamp-based migration versions.
- More detailed error messages to help understand when things go wrong.

### Changed

- Moved `cli.Run` from `pkg` to `internal`

### Fixed

- A handful of unhandled errors which were leading to some silent failures.
- The migration version wasn't being parsed out and converted to its native type during sort. That is now being done, for either version style (sequential or timestamp).

## [0.2.1] - 2024-01-14

### Fixed

- Fixed a bug where the `bolt.toml` file was not being read for the documented format.

## [0.2.0] - 2024-01-13

### Added

- Support for environment variables to configure bolt. You may now use the TOML configuration file and/or environment variables to specify the configuration options. The environment variables will take precedence over any values set in the TOML configuration file.

  New environment variables
  - `BOLT_MIGRATIONS_DIR_PATH`
  - `BOLT_DB_CONN_HOST`
  - `BOLT_DB_CONN_PORT`
  - `BOLT_DB_CONN_USER`
  - `BOLT_DB_CONN_PASSWORD`
  - `BOLT_DB_CONN_DBNAME`
  - `BOLT_DB_CONN_DRIVER`

- Support for Windows when looking up the user's bolt configuration file.
  Previously, as the filesystem was traversed, it would look for "/" as the
  root directory.

- `bolt down` command to enable rollback of all migrations or optionally to a specific version.

- `bolt up` now supports a `-v` or `-version` flag which allows upgrading to a specific version.

- `bolt version` command to display the current version of bolt.
  
- Support for executing migration scripts without a transaction. Use `-- bolt: no-transaction` as the first line of your migration script to disable transactions for that migration.

### Changed

- `bolt_migrations` `version` column is now 14 characters long instead of 32.

- `bolt migrate` has been renamed to `bolt up`.
  
- `bolt list` has been renamed to `bolt status`.
  
- `bolt create` has been renamed to `bolt new`.

- The `up` command will now exit with a status code of 1
  if it encounters an error while running a migration. Previously,
  it was silently failing.

- `bolt status` output has been updated to be a tabular format.

- `[connection]` in `bolt.toml` should now be `[bolt.db.connection]`.

- `migrations_dir` in `bolt.toml` should now be in a `[bolt.migrations]` section and should now be called `directory_path`.
  
## [0.1.0] - 2023-12-30

### Added

- Initial release

<!-- template
## [X.Y.Z] - YYYY-MM-DD
### Added
- for new features.
### Changed
- for changes in existing functionality.
### Deprecated
- for soon-to-be removed features.
### Removed
- for now removed features.
### Fixed
- for any bug fixes.
### Security
- in case of vulnerabilities.
-->