Skip to content

Commit

Permalink
Merge pull request #198 from hypermodules/clear-stores
Browse files Browse the repository at this point in the history
add clear script
  • Loading branch information
bcomnes authored Jun 26, 2017
2 parents 276c15a + a0f2670 commit f89ce84
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,8 @@
"test:renderer": "tape renderer/**/test.js | tap-format-spec",
"rebuild": "electron-rebuild",
"build": "build --dir",
"dist": "build"
"dist": "build",
"clear": "electron scripts/clear.js"
},
"build": {
"appId": "com.hypermodules.hyperamp",
Expand Down
14 changes: 14 additions & 0 deletions scripts/clear.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/usr/bin/env electron

var Store = require('electron-store')

var config = new Store({ name: 'hyperamp-config' })
var persist = new Store({ name: 'hyperamp-persist' })

console.log('clearing %s', config.path)
config.clear()

console.log('clearing %s', persist.path)
persist.clear()

process.exit(0)

0 comments on commit f89ce84

Please sign in to comment.