@shutter/shutterrc
TypeScript icon, indicating that this package has built-in type declarations

0.4.0 • Public • Published

@shutter/shutterrc NPM Version

Locate and parse the shutter configuration file, .shutterrc. Will start looking for .shutterrc in the currently working directory, then traverse its parents and finally try the user's home directory.

API

import { loadShutterConfig } from '@shutter/shutterrc'

loadShutterConfig(directoryPath: string = process.cwd()): Promise<ShutterConfig>

Locate the .shutterrc file, read and parse it. Start looking in directoryPath.

updateShutterConfig(configFilePath: string, updatedConfig: ShutterConfig): Promise<void>

Write an updated shutter configuration to a .shutterrc file. The targetted .shutterrc may already exist. If not, it will be created.

Pass the whole configuration, not just the entries to update.

getUserConfigPath(): string

Returns the path to the user-specific .shutterrc file.

Sample .shutterrc

authtoken=eyJhbGciO...

Readme

Keywords

none

Package Sidebar

Install

npm i @shutter/shutterrc

Weekly Downloads

1

Version

0.4.0

License

MIT

Unpacked Size

146 kB

Total Files

5

Last publish

Collaborators

  • andywer