Skip to content

Commit

Permalink
add note about stringify to the readme
Browse files Browse the repository at this point in the history
  • Loading branch information
chee committed May 5, 2017
1 parent 7dafb04 commit 996cafc
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions README.md
@@ -1,7 +1,8 @@
# NeXTStep plist parser
# NeXTStep plist parser and writer

parse NeXTStep style plists in node. these are not the xml style, but the older
NeXTStep style (a similar filetype is used in GNUStep, with extensions)
parse and generate NeXTStep style plists in node. these are not the xml style,
but the older NeXTStep style (a similar filetype is used in GNUStep, with
extensions)

the only place i know of to still use them in macOS is
`~/Library/KeyBindings/DefaultKeyBinding.dict`
Expand All @@ -17,11 +18,15 @@ const plist = `{
"~f" = "moveWordForward:",
"~b" = "moveWordBackward:"
}`
const {parse} = require('nextstep-plist')
parse(plist) // {'~f': 'moveWordForward:', '~b': 'moveWordBackward:'}
const {parse, stringify} = require('nextstep-plist')
const js = parse(plist) // {'~f': 'moveWordForward:', '~b': 'moveWordBackward:'}
stringify(js) // '{ "~f" = "moveWordForward:"; "~b": "moveWordBackward":}'
```

## todo
* clean up this code
* support `<binary>` syntax
* support comments
* make the output prettier
* write tests for stringify
* tell @gnarf

0 comments on commit 996cafc

Please sign in to comment.