github suzuki-shunsuke/tfmv v0.2.1

latest releases: v0.2.8, v0.2.7, v0.2.7-0...
8 months ago

Pull Requests | Issues | v0.2.0...v0.2.1

Features

#26 #28 Output a summary of changes

tfmv outputs a summary of changes in JSON format to stdout

$ tfmv -Rr '-/_'
{
  "changes": [
    {
      "dir": "regexp",
      "address": "github_repository.example-1",
      "new_address": "github_repository.example_1"
    },
    {
      "dir": "bar",
      "address": "github_repository.example-1",
      "new_address": "github_repository.example_1"
    },
    {
      "dir": "foo/nest",
      "address": "null_resource.foo-prod",
      "new_address": "null_resource.foo_prod"
    },
    {
      "dir": ".",
      "address": "github_repository.example-1",
      "new_address": "github_repository.example_1"
    }
  ]
}

#31 Validate new names
#25 Support renaming resources by regular expression

The option --regexp is added:

tfmv --regexp '^example-(\d+)/test-$1'

About regular expression, please see the following document:

#24 Support filtering resources using regular expression

Options --include and --exclude are added:

tfmv -r "-/_" --include "^aws_"
tfmv -r "-/_" --exclude "^aws_"

Fixes

#29 Fix references in files other than given files
#27 Fix a bug that references are modified with --dry-run

Don't miss a new tfmv release

NewReleases is sending notifications on new releases.