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

Rename .jsbeautifyrc to .atombeautifyrc #41

Open
donaldpipowitch opened this issue Jul 1, 2014 · 14 comments
Open

Rename .jsbeautifyrc to .atombeautifyrc #41

donaldpipowitch opened this issue Jul 1, 2014 · 14 comments

Comments

@donaldpipowitch
Copy link
Contributor

Hi @Glavin001 and @karolyi,

Before leaving (?) the project (#40) I have one last question/advice:
As you've added new languages we are in the need to clarify the relation to https://github.com/beautify-web/js-beautify.

The project started as an Atom wrapper for js-beautify, but it should be treated independent to js-beautify now.
We already added a non-standard .jsbeautifyrc (#9). I would recommend to deprecate the use of .jsbeautifyrc right now and introduce a .atombeautifyrc. This JSON file collects default settings which can be used for every language, but could be overridden for a specific language (and adds language-specific settings). Something like

{
 "_default": {
    "indent_size": 4,
    "indent_char": " "
  },
  "html": {
    "brace_style": "collapse",
    "indent_scripts": "normal",
    "indent_size": 6,
    "max_preserve_newlines": 1,
    "preserve_newlines": true,
    "unformatted": ["a", "sub", "sup", "b", "i", "u"],
    "wrap_line_length": 0
  },
  "css": {
    "indent_size": 2
  },
  "js": {
    "indent_level": 0,
    "indent_with_tabs": false,
    "preserve_newlines": true,
    "max_preserve_newlines": 2,
    "jslint_happy": true
  },
  "sql": {
    "indent_level": 0,
    "indent_with_tabs": false
  },
  "python": { ... }
}

You could even exchange js-beautify for a different beautifier for JS at a later state or use different beautifier for CSS and HTML, but still use it just for JS.

Just my 2 cents :)

@karolyi
Copy link
Collaborator

karolyi commented Jul 1, 2014

+1 to that. We're way more than just jsbeautify already.

@Glavin001
Copy link
Owner

+1 for changing the configuration file from .jsbeautifyrc to something like .atombeautifyrc.

@Glavin001 Glavin001 changed the title Future goals Future goals - Move away from jsbeautify Jul 10, 2014
@Glavin001
Copy link
Owner

Should we support both with a deprecation warning or something?

@Glavin001 Glavin001 added this to the v1.0.0 milestone Jul 12, 2014
@Glavin001 Glavin001 self-assigned this Jul 12, 2014
@Glavin001 Glavin001 changed the title Future goals - Move away from jsbeautify Rename .jsbeautifyrc to .atombeautifyrc Aug 30, 2014
@Glavin001
Copy link
Owner

  • Show deprecation warning
  • Provide easy-button for users to automatically upgrade and rename their existing (found) .jsbeautifyrc files

@Glavin001
Copy link
Owner

Blocked by #56, GUI for messages.

@ilanbiala
Copy link

I wouldn't change it from .jsbeautifyrc, because not everyone is using Atom. Also, I would actually just build a settings panel into Atom, because that is more across the board and less specific to each project.

@nemoDreamer
Copy link

No longer seems to be picking up the .jsbeautifyrc I have in my project's root...
The settings panel is Ok, although it's massive length makes it very unfriendly to use, but an existing .jsbeautifyrc should override those settings (especially when working in a team that has set such a file globally for use by all IDEs)

@Glavin001
Copy link
Owner

@nemoDreamer .jsbeautifyrc is still the goto file name, so there should not be any problems. The only time when that file is ignored, is if it is not either JSON or YAML and the parsing fails, then it will error silently and try to find other config files.

@nemoDreamer
Copy link

Aha, I'll double-check my quotes etc. thanks!
On Mon, Jun 29, 2015 at 7:39 PM Glavin Wiechert notifications@github.com
wrote:

@nemoDreamer https://github.com/nemoDreamer .jsbeautifyrc is still the
goto file name, so there should not be any problems. The only time when
that file is ignored, is if it is not either JSON or YAML and the parsing
fails, then it will error silently and try to find other config files.


Reply to this email directly or view it on GitHub
#41 (comment)
.

@Glavin001 Glavin001 modified the milestones: v0.30.0, v0.29.0 Mar 30, 2016
@Glavin001 Glavin001 modified the milestones: v0.30.0, v0.31.0 Jun 22, 2017
@stevenzeck
Copy link
Contributor

Looks like something that will be intertwined with Unibeautify.

@Glavin001
Copy link
Owner

I was thinking .beautifyrc. Thoughts?

@prettydiff
Copy link
Collaborator

If the name is changing why not rename it to .unibeautifyrc in consideration for the future effort.

@Glavin001
Copy link
Owner

@prettydiff I thought about that, too, however if .beautifyrc is not taken -- I think it is not -- then using only beautify may help strengthen the association between Unibeautify and beautification.

Unibeautify is the product name, however the problem is beautification. Instead of users thinking "I want to use Unibeautify", I want them to think "I want to beautify my code" and Unibeautify is just the implementation detail they consistently choose. In the same way "Google it" and "Search it" are synonymous, I want Unibeautify to become to "go to" for code beautification.

I want .beautifyrc to become the best standard for describing how we declare our code formatting configuration (similar to .editorconfig), regardless of Unibeautify being the runtime. However, let's make Unibeautify the best option available 😉 .

@stevenzeck
Copy link
Contributor

Also, should make whatever that file ends up being easily portable. I can envision teams with their editors/IDEs needing to have the same beautification configuration so their source control doesn't keep picking up unnecessary changes.

@Glavin001 Glavin001 modified the milestones: v0.31.0, v0.33.0 (Next) Mar 2, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants