Rocky_Mountain_Vending/.pnpm-store/v10/files/4d/f9b98c426e04d26107ca6edc83e3d3e49b73d9df1812488c806d37f6372e5eb5c3a1e82f18628b408ae787220df619bdcafa2f31d057c786df1623c8e31364
DMleadgen 46d973904b
Initial commit: Rocky Mountain Vending website
Next.js website for Rocky Mountain Vending company featuring:
- Product catalog with Stripe integration
- Service areas and parts pages
- Admin dashboard with Clerk authentication
- SEO optimized pages with JSON-LD structured data

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 16:22:15 -07:00

105 lines
2.7 KiB
Text

# @smithy/shared-ini-file-loader
[![NPM version](https://img.shields.io/npm/v/@smithy/shared-ini-file-loader/latest.svg)](https://www.npmjs.com/package/@smithy/shared-ini-file-loader)
[![NPM downloads](https://img.shields.io/npm/dm/@smithy/shared-ini-file-loader.svg)](https://www.npmjs.com/package/@smithy/shared-ini-file-loader)
## AWS Shared Configuration File Loader
This module provides a function that reads from AWS SDK configuration files and
returns a promise that will resolve with a hash of the parsed contents of the
AWS credentials file and of the AWS config file. Given the [sample
files](#sample-files) below, the promise returned by `loadSharedConfigFiles`
would resolve with:
```javascript
{
configFile: {
'default': {
aws_access_key_id: 'foo',
aws_secret_access_key: 'bar',
},
dev: {
aws_access_key_id: 'foo1',
aws_secret_access_key: 'bar1',
},
prod: {
aws_access_key_id: 'foo2',
aws_secret_access_key: 'bar2',
},
'testing host': {
aws_access_key_id: 'foo4',
aws_secret_access_key: 'bar4',
}
},
credentialsFile: {
'default': {
aws_access_key_id: 'foo',
aws_secret_access_key: 'bar',
},
dev: {
aws_access_key_id: 'foo1',
aws_secret_access_key: 'bar1',
},
prod: {
aws_access_key_id: 'foo2',
aws_secret_access_key: 'bar2',
}
},
}
```
If a file is not found, its key (`configFile` or `credentialsFile`) will instead
have a value of an empty object.
## Supported configuration
You may customize how the files are loaded by providing an options hash to the
`loadSharedConfigFiles` function. The following options are supported:
- `filepath` - The path to the shared credentials file. If not specified, the
provider will use the value in the `AWS_SHARED_CREDENTIALS_FILE` environment
variable or a default of `~/.aws/credentials`.
- `configFilepath` - The path to the shared config file. If not specified, the
provider will use the value in the `AWS_CONFIG_FILE` environment variable or a
default of `~/.aws/config`.
- `ignoreCache` - The provider will normally cache the contents of the files it
loads. This option will force the provider to reload the files from disk.
Defaults to `false`.
## Sample files
### `~/.aws/credentials`
```ini
[default]
aws_access_key_id=foo
aws_secret_access_key=bar
[dev]
aws_access_key_id=foo2
aws_secret_access_key=bar2
[prod]
aws_access_key_id=foo3
aws_secret_access_key=bar3
```
### `~/.aws/config`
```ini
[default]
aws_access_key_id=foo
aws_secret_access_key=bar
[profile dev]
aws_access_key_id=foo2
aws_secret_access_key=bar2
[profile prod]
aws_access_key_id=foo3
aws_secret_access_key=bar3
[profile "testing host"]
aws_access_key_id=foo4
aws_secret_access_key=bar4
```