Change all references from .terraformrc to .opentfrc

This commit is contained in:
Yaron Yarimi 2023-08-20 18:49:32 +03:00
parent e9198b1d24
commit e55369b364
4 changed files with 10 additions and 10 deletions

View File

@ -87,8 +87,8 @@ var BuiltinConfig Config
// ConfigFile returns the default path to the configuration file.
//
// On Unix-like systems this is the ".terraformrc" file in the home directory.
// On Windows, this is the "terraform.rc" file in the application data
// On Unix-like systems this is the ".opentfrc" file in the home directory.
// On Windows, this is the "opentf.rc" file in the application data
// directory.
func ConfigFile() (string, error) {
return configFile()
@ -146,7 +146,7 @@ func LoadConfig() (*Config, tfdiags.Diagnostics) {
return config, diags
}
// loadConfigFile loads the CLI configuration from ".terraformrc" files.
// loadConfigFile loads the CLI configuration from ".opentfrc" files.
func loadConfigFile(path string) (*Config, tfdiags.Diagnostics) {
var diags tfdiags.Diagnostics
result := &Config{}

View File

@ -171,7 +171,7 @@ func (s PluginMetaSet) ConstrainVersions(reqd PluginRequirements) map[string]Plu
// names are removed and replaced with the single path given in the map.
//
// This is here only to continue to support the legacy way of overriding
// plugin binaries in the .terraformrc file. It treats all given plugins
// plugin binaries in the .opentfrc file. It treats all given plugins
// as pre-versioning (version 0.0.0). This mechanism will eventually be
// phased out, with vendor directories being the intended replacement.
func (s PluginMetaSet) OverridePaths(paths map[string]string) PluginMetaSet {

View File

@ -5,7 +5,7 @@ description: >-
including credentials, plugin caching, provider installation methods, etc.
---
# CLI Configuration File (`.terraformrc` or `terraform.rc`)
# CLI Configuration File (`.opentfrc` or `opentf.rc`)
The CLI configuration file configures per-user settings for CLI behaviors,
which apply across all Terraform working directories. This is separate from
@ -16,18 +16,18 @@ which apply across all Terraform working directories. This is separate from
The configuration can be placed in a single file whose location depends
on the host operating system:
* On Windows, the file must be named `terraform.rc` and placed
* On Windows, the file must be named `opentf.rc` and placed
in the relevant user's `%APPDATA%` directory. The physical location
of this directory depends on your Windows version and system configuration;
use `$env:APPDATA` in PowerShell to find its location on your system.
* On all other systems, the file must be named `.terraformrc` (note
* On all other systems, the file must be named `.opentfrc` (note
the leading period) and placed directly in the home directory
of the relevant user.
On Windows, beware of Windows Explorer's default behavior of hiding filename
extensions. Terraform will not recognize a file named `terraform.rc.txt` as a
extensions. OpenTF will not recognize a file named `opentfc.rc.txt` as a
CLI configuration file, even though Windows Explorer may _display_ its name
as just `terraform.rc`. Use `dir` from PowerShell or Command Prompt to
as just `opentf.rc`. Use `dir` from PowerShell or Command Prompt to
confirm the filename.
The location of the Terraform CLI configuration file can also be specified

View File

@ -148,7 +148,7 @@ export TF_REGISTRY_CLIENT_TIMEOUT=15
The location of the [Terraform CLI configuration file](/terraform/cli/config/config-file).
```shell
export TF_CLI_CONFIG_FILE="$HOME/.terraformrc-custom"
export TF_CLI_CONFIG_FILE="$HOME/.opentfrc-custom"
```
## TF_PLUGIN_CACHE_DIR