Skip to content

Commit

Permalink
Added readOnly docs.
Browse files Browse the repository at this point in the history
  • Loading branch information
igoramadas committed Apr 30, 2020
1 parent 0577635 commit 0fadc6b
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,21 @@ settings.myFTP = {
}
```

## Read only mode

```javascript
const setmeup = require("setmeup")

// Enabling readOnly mode will prevent SetMeUp from ever writing to disk.
setmeup.readOnly = true

// File settings.secret.json (if present) will not be auto encrypted.
setmeup.load()

// Calling encrypt in readOnly mode won't work now.
setmeup.encrypt("settings.custom.json")
```

### Watching updates to configuration files

```javascript
Expand Down

0 comments on commit 0fadc6b

Please sign in to comment.