athar 0.2.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 5b0ef1986b6cadc08da710ef20abb9526c86f097bc032bf881ea9edb669884cd
|
|
4
|
+
data.tar.gz: 0cbadc431bdcc7c390f3e7e4d4e9bb8f2f80c269f770c7b855228fd1988da8b1
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 05d969a0d558f38df5377489cadf8474c224838613714df374759e60a558a42de329d345b9aebe827a5b77bdf5f49aa57d96eaacc48525a56b6e3d85e3d9f596
|
|
7
|
+
data.tar.gz: 84b6440c8e7f7b2225c03c3440b469dae05aafb68aeee4ef7cd1a7972e361d10036acdc1f3b076d4824246951dfb9fa4845630ec350b2cd07cfa4b7fda3d2700
|
data/CHANGELOG.md
CHANGED
|
@@ -6,6 +6,12 @@ The format is based on Keep a Changelog, and this project adheres to Semantic Ve
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [0.2.1] - 2026-05-06
|
|
10
|
+
|
|
11
|
+
### Fixed
|
|
12
|
+
|
|
13
|
+
- Fixed `athar:install --update` migrations to replace SQL functions without dropping them, avoiding PostgreSQL dependency errors when existing triggers depend on `athar_capture_delete()`.
|
|
14
|
+
|
|
9
15
|
## [0.2.0] - 2026-05-05
|
|
10
16
|
|
|
11
17
|
### Added
|
data/lib/athar/version.rb
CHANGED
|
@@ -60,11 +60,13 @@ class <%= migration_class_name %> < ActiveRecord::Migration[<%= ActiveRecord::Mi
|
|
|
60
60
|
drop_table :athar_deletions if table_exists?(:athar_deletions)
|
|
61
61
|
<% end -%>
|
|
62
62
|
|
|
63
|
+
<% unless update? -%>
|
|
63
64
|
execute(<<~SQL)
|
|
64
65
|
<% function_drops.each do |drop_sql| -%>
|
|
65
66
|
<%= drop_sql %>
|
|
66
67
|
<% end -%>
|
|
67
68
|
SQL
|
|
69
|
+
<% end -%>
|
|
68
70
|
end
|
|
69
71
|
<% unless update? -%>
|
|
70
72
|
private
|
|
@@ -53,9 +53,15 @@ class <%= migration_class_name %> < ActiveRecord::Migration[<%= ActiveRecord::Mi
|
|
|
53
53
|
<% elsif function_definition[:previous_version] == function_definition[:version] -%>
|
|
54
54
|
# <%= function_definition[:name] %> is already at version <%= function_definition[:version] %>; nothing to do.
|
|
55
55
|
<% else -%>
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
56
|
+
reversible do |dir|
|
|
57
|
+
dir.up do
|
|
58
|
+
create_function :<%= function_definition[:name] %>, version: <%= function_definition[:version] %>
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
dir.down do
|
|
62
|
+
create_function :<%= function_definition[:name] %>, version: <%= function_definition[:previous_version] %>
|
|
63
|
+
end
|
|
64
|
+
end
|
|
59
65
|
<% end -%>
|
|
60
66
|
<% end -%>
|
|
61
67
|
end
|