An open API service indexing awesome lists of open source software.

https://github.com/vladimyr/shell-profile

Node library for retrieving default shell profile path
https://github.com/vladimyr/shell-profile

nodejs shell shell-profile

Last synced: 2 months ago
JSON representation

Node library for retrieving default shell profile path

Awesome Lists containing this project

README

          

# shell-profile [![build status](https://badgen.net/travis/vladimyr/shell-profile/master)](https://travis-ci.com/vladimyr/shell-profile) [![install size](https://badgen.net/packagephobia/install/shell-profile)](https://packagephobia.now.sh/result?p=shell-profile) [![npm package version](https://badgen.net/npm/v/shell-profile)](https://npm.im/shell-profile) [![github license](https://badgen.net/github/license/vladimyr/shell-profile)](https://github.com/vladimyr/shell-profile/blob/master/LICENSE) [![js semistandard style](https://badgen.net/badge/code%20style/semistandard/pink)](https://github.com/Flet/semistandard)

> get default shell profile path

# Usage

```js
const shellProfile = require('shell-profile');
console.log('profile: %s', shellProfile());
//=> profile: /Users/vladimyr/.zshrc
```

# API

### Table of Contents

- [getProfilePath](#getprofilepath)
- [Examples](#examples)

## getProfilePath

Synchronously gets default shell profile path

### Examples

```javascript
const profile = require('shell-profile')();
console.log('profile: %s', profile);
//=> profile: /Users/vladimyr/.zshrc
```

Returns **[Promise](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise)<[String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)?>** profile path