Add Settings option to Atom Beautify menu to access package settings

This commit is contained in:
Steven Zeck 2017-10-18 18:44:52 -05:00
parent 30dece209a
commit 4522232642
4 changed files with 10 additions and 0 deletions

View File

@ -1,6 +1,7 @@
# Next
- See [#881](https://github.com/Glavin001/atom-beautify/issues/881). Update to Prettydiff version 2!
- Fix for [#1888](https://github.com/Glavin001/atom-beautify/issues/1888). Allow 0 for minor and patch versions of Docker
- Add Settings to atom-beautify in Packages menu [#1869](https://github.com/Glavin001/atom-beautify/issues/1869)
- ...
# v0.30.5 (2017-08-11)

View File

@ -25,6 +25,10 @@
'label': 'Debug'
'command': 'atom-beautify:help-debug-editor'
}
{
'label': 'Settings'
'command': 'atom-beautify:open-settings'
}
]
]
}

View File

@ -208,6 +208,7 @@
"atom-workspace": [
"atom-beautify:help-debug-editor",
"atom-beautify:beautify-editor",
"atom-beautify:open-settings",
"atom-beautify:migrate-settings",
"core:save",
"core:save-as",

View File

@ -556,6 +556,9 @@ handleSaveEvent = ->
)
plugin.subscriptions.add disposable
openSettings = ->
atom.workspace.open('atom://config/packages/atom-beautify')
getUnsupportedOptions = ->
settings = atom.config.get('atom-beautify')
schema = atom.config.getSchema('atom-beautify')
@ -622,6 +625,7 @@ plugin.activate = ->
@subscriptions.add handleSaveEvent()
@subscriptions.add atom.commands.add "atom-workspace", "atom-beautify:beautify-editor", beautify
@subscriptions.add atom.commands.add "atom-workspace", "atom-beautify:help-debug-editor", debug
@subscriptions.add atom.commands.add "atom-workspace", "atom-beautify:open-settings", openSettings
@subscriptions.add atom.commands.add ".tree-view .file .name", "atom-beautify:beautify-file", beautifyFile
@subscriptions.add atom.commands.add ".tree-view .directory .name", "atom-beautify:beautify-directory", beautifyDirectory
@subscriptions.add atom.commands.add "atom-workspace", "atom-beautify:migrate-settings", plugin.migrateSettings