-
Notifications
You must be signed in to change notification settings - Fork 211
add options to apply formatting by file extension, file syntax, or both#81
add options to apply formatting by file extension, file syntax, or both #81owenleonard wants to merge 1 commit into
Conversation
jdavisclark
commented
Sep 1, 2013
looks good.
As soon as we get #79 finished up I'll merge this in.
owenleonard
commented
Sep 9, 2013
Thanks. Let me know if I can do anything to help.
jdavisclark
commented
Sep 16, 2013
Promise I haven't forgotten this. I branched off from your pull request and added some more functionality to it; haven't pushed up to a feature branch yet though. Trying to make sure It's well though out before we publish, as it's the type of thing where I keep thinking of more little details that are convenient to make configurable via user settings.
I'll push up to a feature branch some time this week so people can have a look at it.
jdavisclark
commented
Nov 5, 2013
@owenleonard Alright, I know this is ridiculously late, but have a look at the changes in the plugin_activation branch. I took what you started with and added a few more options to it. Welcoming any feedback.
jackocnr
commented
Mar 13, 2014
Hi @jdc0589 did this ever get merged in? Are you still waiting for feedback? If so, how would I go about installing JsFormat from that specific branch?
Thanks for your work on this.
jdavisclark
commented
Mar 13, 2014
@jackocnr it's not merged in yet, mainly because I've been a bad project maintainer lately and forgot about it. mite-node has been taking up a lot of my free time lately...
There have been a few additions in master since the work on that branch, but you could install from the plugin_activation branch if you want to have a look at it, I would certainly appreciate any feedback.
To install that branch, remove the existing JsFormat package, navigate to [Sublime Root]/Packages, git clone this repo there, and then fetch + checkout the plugin_activation branch. Then have a look at the documentation for the new jsFormat specific settings in that branch.
I need to review it all, but it looks like it can still be merged to master relatively easily. I'll try and get it in soon.
ctf0
commented
Oct 1, 2014
as a temp solution for ignoring json formatting ,u can use a plugin call Hook and add this to ur user settings file
"on_pre_save_language": [
{
"command": "js_format",
"context": [{"key": "selector", "operator": "equal", "operand": "source.js"}]
},
]
but to say the least ,the plugin_activation branch has some ridiculously awesome options which i hope it get merged sometime soon.
kurtextrem
commented
Dec 25, 2014
Any news? This feature would be great.
I saw issue 69 (#69) and it related to something I was trying to figure out. I like the formatting that jsbeautify does for javascript, but not for JSON. I just find it expands things too much. So, I wanted to be able to continue using jsFormat for javascript files, but not for JSON files.
Since issue 69 also wanted to exclude js.erb files from being formatted, I thought a good solution would be to allow the user to configure jsFormat to format files based on file extension, file syntax, or both. This way, you can enable/disable jsFormat for a file extension regardless of the content of the file, or you can configure it to format based on file syntax regardless of the file extension. The defaults leave the functionality the same as before the changes.
Let me know what you think about these changes. Any recommendations? Optimizations?