Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update js-beautify CLI options in README #1089

Merged
merged 1 commit into from
Jan 3, 2017

Conversation

olsonpm
Copy link
Contributor

@olsonpm olsonpm commented Dec 29, 2016

fixes #1047

  • update cli options with exact output from $ js-beautify --help
  • add missing json defaults found in the CLI
  • reorder json defaults to correspond with CLI output
  • remove 'keep_function_indentation' from documentation since it is unused
  • remove html beautifier specific defaults (updating that section is out of
    scope for this commit)
  • separate defaults exposed by the cli and those which aren't
  • reword the compatibility notice as a result of the default separation

@olsonpm
Copy link
Contributor Author

olsonpm commented Dec 29, 2016

This is a little more than what #1047 called for, but I wanted to update that section as a whole. Let me know if it's too much and I'll keep the commit limited to the operator_position

Copy link
Member

@bitwiseman bitwiseman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You have the right instinct. Make it match the output from help. Might as well add fixing up the help output to this.

-s, --indent-size Indentation size [4]
-c, --indent-char Indentation character [" "]
-e, --eol character(s) to use as line terminators. (default newline - "\\n")');
-s, --indent-size Indentation size [4]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about fixing the output from --help to make this indentation even?

Copy link
Contributor Author

@olsonpm olsonpm Dec 30, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because I didn't think it was broken haha. My understanding of the pattern was a loosely tiered "match your neighbor's indentation". I take it you don't want the options under "CLI Options" to be pushed over, just those under "Beautifier Options"? I'll update it to whatever you think looks good.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh whoops - I have no idea how that indentation changed. I definitely didn't do that on purpose, I'll have to check to see if my editor is being smarter than it should be.

Sorry for that

@olsonpm
Copy link
Contributor Author

olsonpm commented Dec 30, 2016

the indentation should be fixed with that push -f.

@bitwiseman
Copy link
Member

@abbotto - Does this fully address your concerns from #1047?

@olsonpm
Copy link
Contributor Author

olsonpm commented Dec 30, 2016

@bitwiseman

  • ah, I remembered why the indentation changed:

http://pix.toile-libre.org/upload/original/1483098688.png

That's from a fresh npm i -g js-beautify

Should I even out the indentation in the CLI as well?

@bitwiseman
Copy link
Member

@olsonpm - yes, please go ahead and even that out while you're at it. Thanks!

@olsonpm olsonpm force-pushed the update-readme-cli-options branch 2 times, most recently from 07828b8 to 90037b4 Compare January 2, 2017 20:45
@olsonpm
Copy link
Contributor Author

olsonpm commented Jan 2, 2017

I'm not understanding why appveyor and travis are tripping up.

Ensuring no changes visible to git have been made to '' ...

ERROR: Post-build git status check - FAILED.

?

@bitwiseman
Copy link
Member

bitwiseman commented Jan 2, 2017 via email

@bitwiseman bitwiseman closed this Jan 2, 2017
@bitwiseman bitwiseman reopened this Jan 2, 2017
@bitwiseman
Copy link
Member

Ah, I see. Run ./build and then amend your commit.

fixes beautifier#1047

 - update cli options with exact output from `$ js-beautify --help`
 - even out indentation under CLI "Beautifier Options"
 - add missing json defaults found in the CLI
 - reorder json defaults to correspond with CLI output
 - remove 'keep_function_indentation' from documentation since it is unused
 - remove html beautifier specific defaults (updating that section is out of
   scope for this commit)
 - separate defaults exposed by the cli and those which aren't
 - reword the compatibility notice as a result of the default separation
@olsonpm
Copy link
Contributor Author

olsonpm commented Jan 2, 2017

thanks

@bitwiseman
Copy link
Member

@olsonpm - Thanks you!

@bitwiseman bitwiseman merged commit 1546edf into beautifier:master Jan 3, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Explaination of 'operator_position' is absent from README.md
2 participants