From 187024974a4acef2c520633069a601a5a7fe8016 Mon Sep 17 00:00:00 2001 From: Sergey Zhemoytel Date: Sun, 9 Oct 2022 14:05:18 +0300 Subject: [PATCH] Imported from SRPM --- .abf.yml | 2 ++ tfautomv.spec | 42 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 44 insertions(+) create mode 100644 .abf.yml create mode 100644 tfautomv.spec diff --git a/.abf.yml b/.abf.yml new file mode 100644 index 0000000..4b5514c --- /dev/null +++ b/.abf.yml @@ -0,0 +1,2 @@ +sources: + tfautomv-0.3.1.tar.gz: 03a97f948ba57de72b89dc788ebd2c2b6a808f68 diff --git a/tfautomv.spec b/tfautomv.spec new file mode 100644 index 0000000..8148f5d --- /dev/null +++ b/tfautomv.spec @@ -0,0 +1,42 @@ +%define debug %nil +%define debug_package %nil + +Name: tfautomv +Version: 0.3.1 +Release: 1 +Summary: Generate Terraform moved blocks automatically for painless refactoring +URL: https://github.com/padok-team/tfautomv +Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz +License: ASL 2.0 +Group: Development/Other +BuildRequires: go +BuildRequires: git-core +BuildRequires: upx + +%description +When you move a resource in your code, Terraform loses +track of the resource's state. The next time you run +Terraform, it will plan to delete the resource it has +memory of and create the "new" resource it found in your +refactored code. + +tfautomv inspects the output of terraform plan, detects +such creation/deletion pairs and writes a moved block so +that Terraform now knows no deletion or creation is required. + +%prep +%setup -q + + +%build +%make build +upx bin/%{name} + + +%install +install -Dm0755 bin/%{name} %{buildroot}%{_bindir}/%{name} + +%files +%doc README.md LICENSE +%{_bindir}/%{name} +