Commit Graph

326 Commits

Author SHA1 Message Date
Glavin Wiechert 6ea9788255 Merge branch 'master' of https://github.com/fdelbos/atom-beautify into fdelbos-master 2016-04-23 16:41:20 -03:00
Glavin Wiechert 8ce6e5d376 Merge pull request #943 from ayoubdev/master
[PrettyDiff] Fixed Indent Tabs configuration ignored (issue: #910: ht…
2016-04-23 16:38:36 -03:00
ayoubdev 0152863484 [PrettyDiff] Fixed Indent Tabs configuration ignored (issue: #910: https://github.com/Glavin001/atom-beautify/issues/910) 2016-04-23 18:49:20 +02:00
Garret Wilson 268e1f5d80 Fix issue #707 by adding Atom-based EOL detection
Determines the default line ending based upon the Atom configuration
`line-ending-selector.defaultLineEnding`. If the Atom configuration
indicates "OS Default", the `process.platform` is queried, returning
CRLF for Windows systems and LF for all other systems.
2016-04-22 19:16:55 -07:00
Glavin Wiechert 4eb8607c47 Fixes #924. Prevent infinite loop with beautify on save
With the option `Ensure Single Trailing Newline` option enabled
in the Whitespace package, Atom would append a newline character after
beautification had occured and when the beautified code was saved it
would be changed and never settle on a stable text that would not change
the previously saved text in the editor. Thus an infinite loop on save.
2016-04-19 20:16:16 -03:00
Glavin Wiechert a730f33ff2 Fixes #924. Beautify On Save changes the TextEditor not the file
It seems that in a recent update of Atom, Atom-Beautify's beautify on
save feature would actually crash Atom and in some cases even delete all
of the contents of the file!

After some investigation, it looks like writing directly to the file
with fs.write may have been the culprit and crashing Atom.
2016-04-19 19:22:23 -03:00
Frederic Delbos 8b237edbee add ocaml language 2016-04-19 23:15:36 +02:00
Petru Ilies 58f7a868d7 Merge remote-tracking branch 'upstream/master' 2016-04-18 10:35:46 +03:00
Glavin Wiechert c950557438 Change cross-spawn dependency to be optionalDependency
Closes #573, #795, #922, #858, #925, #761, #902, #740.

If cross-spawn fails to install, atom-beautify will still continue to
install and work without it, with degraded support for Windows, such as
ignoring PATHEXT.
2016-04-16 19:55:13 -03:00
Glavin Wiechert 83ecac5d7e See #924. Add more verbose debugging to beautifyFilePath 2016-04-16 16:18:10 -03:00
Glavin Wiechert 78c2cc5480 See #864. Fix Logger to use renamed loggerLevel setting key 2016-04-16 16:16:56 -03:00
Glavin Wiechert c0b3ba3557 See #919. Remove options from analytics tracking
Originally tracking `options` was intended to help with debugging errors, and making sure Atom-Beautify was working for the users.
However, we now have that `Help Debug Editor` command that users can use on their own when submitting an Issue for Atom-Beautify on GitHub.
Thus, tracking the `options` is not being used for analytics (yet) and it is more advantageous to remove to reduce the information being tracked.
2016-04-14 23:24:56 -03:00
Glavin Wiechert b23f2816cc Merge pull request #899 from janmolnar/master
running provided emacs binary directly instead of running it via pyth…
2016-04-14 22:02:46 -03:00
ewgenius 4788deaa6d adding Pug extension and grammar
*.pug files can't be beautified
2016-04-13 08:18:29 +03:00
Glavin Wiechert aeb39566ab Closes #905. Add Handlebars support to Pretty Diff beautifier 2016-04-12 00:30:05 -03:00
Jan-Cornelius Molnar 55445d66ad fixed non empty check of emacs path 2016-04-10 17:31:49 +02:00
Mark Tofan 992999b347 Seems that Crystal dosen't have Windows support yet. 2016-04-08 22:38:07 +03:00
Petru Ilies 3fe678ce31 Merge branch 'master' of github.com:Glavin001/atom-beautify 2016-04-08 19:30:38 +03:00
Glavin Wiechert 11069f6b42 See #898. Improve notification for unsupported settings
Also update Lodash dependency.
2016-04-08 09:57:19 -03:00
Glavin Wiechert 4cdb738d28 See #898. Add more tests for migrate settings helper 2016-04-07 11:35:15 -03:00
Mark Tofan 0df1d8a5df Added support for Crystal language 2016-04-07 00:00:20 +03:00
Jan-Cornelius Molnar e949efa908 Merge remote-tracking branch 'upstream/master'
Conflicts:
	src/beautifiers/fortran-beautifier/index.coffee
2016-04-06 22:45:37 +02:00
Jan-Cornelius Molnar d79eda0756 running provided emacs binary directly instead of running it via python which does not work well on windows.
listening to emacs return codes.
2016-04-06 22:21:43 +02:00
Glavin Wiechert 14700008b1 Merge pull request #885 from Alhadis/deprecation-fix
Fix deprecation warnings triggered by TextEditor methods
2016-04-01 22:38:52 -03:00
Alhadis bbae6043d5 Fix deprecation warnings triggered by TextEditor methods 2016-04-02 11:05:16 +11:00
Glavin Wiechert 5b3e28b250 See #875. Add test for looking upwards .jsbeautifyrc files 2016-04-01 18:59:07 -03:00
Glavin Wiechert afa27fd50b See #864. Add Migration command from old option keys to new keys
Old:
    { LANG_OPTION: 'VALUE' }
New:
    { LANG: { OPTION: 'VALUE' }}
2016-04-01 16:57:30 -03:00
Glavin Wiechert fa9dd8dd4f Merge branch 'master' into better-settings 2016-04-01 10:40:26 -03:00
Glavin Wiechert d48768e503 Closes #199. Add Jade/Pug beautify support 2016-03-30 10:34:49 -03:00
Glavin Wiechert 50ad73d324 Fixes #879. Fix circular structure in JSON config/settings 2016-03-30 10:29:40 -03:00
Glavin Wiechert caabb95ed7 See #713. Properly extract configuration from package settings 2016-03-30 01:27:54 -03:00
Glavin Wiechert f65453d7bb See #876, #679. Build beautifier options postinstall instead of activate 2016-03-29 15:49:51 -03:00
Glavin Wiechert 232a91bb20 Merge branch 'master' of github.com:Glavin001/atom-beautify into better-settings 2016-03-29 14:41:43 -03:00
Dheepak Krishnamurthy 337d308296 Remove --style flag from yapf
The --style flag accepts different types of input. From their documentation - "accepts one of the predefined styles (e.g., pep8 or google), a path to a configuration file that specifies the desired style, or a dictionary of key/value pairs."

By not explicitly specifying the --style flag, yapf will look for the following, in that order

1. In the [style] section of a .style.yapf file in either the current directory or one of its parent directories.
2. In the [yapf] secionf of a setup.cfg file in either the current directory or one of its parent directories.
3. In the ~/.config/yapf/style file in your home directory.
2016-03-25 23:12:02 -06:00
Glavin Wiechert 4f9981cd83 Merge pull request #845 from Focus/master
Adds LaTeX language support
2016-03-25 23:43:14 -03:00
Michael Hancock 18ae07eaff Added opencl language support
OpenCL language support is achieved here simply by attaching '.CL'
extension to the 'C' language module. OpenCL is C based however beautify
will not support beautification despite having C language support, due
to the different file extension.
2016-03-24 00:34:55 +00:00
Glavin Wiechert 0121920317 See #717. Remove unsupported options for Coldfusion language 2016-03-21 13:56:01 -03:00
Glavin Wiechert ba25e1bce3 See #405, #782. Improve description of Beautify Entire File On Save option 2016-03-21 13:48:19 -03:00
Glavin Wiechert 9d88fe880d See #713. Update options documentation generator for new settings structure 2016-03-21 13:46:52 -03:00
Glavin Wiechert 74526b6821 See #713. Extract General options from package settings 2016-03-21 11:44:52 -03:00
Glavin Wiechert 2be35ca657 See #713. Delete options that do not have a supported beautifier 2016-03-21 11:21:30 -03:00
Glavin Wiechert bc8c2a835b See #713. Include options from language's fallback 2016-03-21 11:00:12 -03:00
Glavin Wiechert 48718d532c See #713. Nest language config options under Language group 2016-03-21 10:43:31 -03:00
Glavin Wiechert 99073d1e02 Fixes #758. Add XTemplate support to Pretty Diff beautifier 2016-03-21 10:39:48 -03:00
Glavin Wiechert 0c3f02d3da Fixes #766. Change default beautifier of Riotjs to Pretty Diff 2016-03-21 10:38:54 -03:00
Glavin Wiechert 433ba8e9b5 See #713. Change key from _general to general for settings 2016-03-21 01:51:30 -03:00
Glavin Wiechert 5c3d21cc70 Revert "Revert "Organize settings/options into groups that will be collapsable""
This reverts commit d97b2d2e4d.
2016-03-21 01:48:29 -03:00
Focus 75ca70bc1f Tabs changed to literal and default to using tabs 2016-03-05 10:07:23 +00:00
Glavin Wiechert bd6e735f08 See #839, #844. Add test for unique language namespaces
Removed check in Beautifiers#buildOptionsForBeautifiers
2016-03-03 20:06:23 -04:00
Glavin Wiechert d637317826 Update Lodash to v4.6.1 2016-03-03 19:49:20 -04:00
Focus ff377a7a3a Implemented options and a clean layout 2016-03-03 21:06:05 +00:00
Glavin Wiechert 3f51b02e25 Fixes #839. Throw error if languages have same namespace
Also fix XTemplate & Riot.js
2016-03-02 12:47:28 -04:00
Focus a4ff384dbf Implements #384 2016-03-02 16:45:56 +00:00
Focus df6599f2c6 Basic implementation for latex with latexindent.pl 2016-03-02 15:35:56 +00:00
Glavin Wiechert 3a6763a25c See #828, #757, #731, #750. Fix Riot.js support,
add support to Pretty diff beautifier
2016-02-25 23:30:34 -04:00
Glavin Wiechert d97b2d2e4d Revert "Organize settings/options into groups that will be collapsable"
This reverts commit f2968b797f.
2016-02-25 23:20:36 -04:00
Glavin Wiechert 792238560b Merge branches 'better-settings' and 'master' of github.com:Glavin001/atom-beautify 2016-02-25 15:20:16 -04:00
Glavin Wiechert e89e1d52ad Merge pull request #825 from jdcrensh/master
Include Apex extension: "trigger"
2016-02-22 10:58:48 -04:00
Jon Crenshaw 8d36215d24 Include Apex extension: "trigger" 2016-02-22 00:37:24 -08:00
Glavin Wiechert f2968b797f Organize settings/options into groups that will be collapsable
Waiting on Atom/settings-view support: https://github.com/atom/settings-view/pull/736
2016-02-22 01:17:07 -04:00
ra100 7003ab934f Merge remote-tracking branch 'upstream/master' 2016-02-21 23:58:18 +01:00
ra100 a826edd3fe fix error when no path to phpcbf is set 2016-02-21 23:56:06 +01:00
Glavin Wiechert aedf6adfba See #733. Remove dfmt from being default beautifier for D language 2016-02-21 17:23:02 -04:00
Glavin Wiechert 080bc994b1 See #733. Add language-d for testing and "d" extension to language file 2016-02-21 16:40:35 -04:00
Glavin Wiechert 286a55486f Merge pull request #766 from prettydiff/riotjs
Updating riotjs.coffee per comment: https://github.com/Glavin001/atom
2016-02-20 15:34:16 -04:00
Glavin Wiechert 34a3297858 Merge branch 'master' of git://github.com/jdcrensh/atom-beautify into jdcrensh-master 2016-02-20 15:32:57 -04:00
Glavin Wiechert 19be23015a Merge pull request #791 from diegodorado/rc-file-check
Wraps .jsbeautifyrc file read into a try/catch since it could be no l…
2016-02-20 15:31:30 -04:00
Glavin Wiechert e74746d32f Merge pull request #790 from sidred/rustfmt-update
Rust - Add ability to read rustfmt.toml
2016-02-20 15:30:38 -04:00
Glavin Wiechert 42a747ca80 Merge pull request #779 from kaaloo/collapse-preserve-inline
[#776] Bump jsbeautify to 1.6.2.  Add support for collapse-preserve-inline
2016-02-20 15:29:45 -04:00
Glavin Wiechert e43952c7d3 Merge pull request #744 from ra100/master
PHPCBF (PHP_CodeSniffer) + Remark for Markdown support
2016-02-20 15:27:52 -04:00
Glavin Wiechert 0ed9e2ae31 Merge pull request #743 from cosmix/develop
Adds 'unchanged' option to the SQL beautifier
2016-02-20 15:26:18 -04:00
Glavin Wiechert f318929046 See #733. No options are supported yet by dfmt 2016-02-20 15:25:19 -04:00
Glavin Wiechert 2b6b026cc6 Merge pull request #733 from LaurentTreguier/master
Adding dfmt support for D
2016-02-20 15:24:54 -04:00
Glavin Wiechert bdcccf8036 Merge pull request #726 from joshholl/master
See #524. Added pretty diff ternaryline option
2016-02-20 15:17:41 -04:00
Glavin Wiechert e90a6335e3 Merge branch 'cfml' of git://github.com/finalcut/atom-beautify into finalcut-cfml 2016-02-20 15:13:27 -04:00
Glavin Wiechert dee67da140 Merge branch 'master' of git://github.com/markbaas/atom-beautify into markbaas-master 2016-02-20 15:11:49 -04:00
Jon Crenshaw 718184554a Add Apex language support
Include support for Salesforce's Java-like "Apex" language
2016-02-17 21:54:08 -08:00
Diego Dorado f99e24cf6c Wraps .jsbeautifyrc file read into a try/catch since it could be no longer available. 2016-02-09 12:19:16 -03:00
sid f5f118a3d2 Add ability to read rustfmt.toml
atom-beautifier runs rustfmt in a tmp folder and rustfmt with not pick up
the rustfmt.toml file in any of the crate root folders or its parent folders.
This commit adds the --config-path parameter with the current folder and will
load any rust format in the file's path

Also set the --write-output format to override from the default setting replace.
This will avoid creating an unnecessary backup file tmp source file
2016-02-09 11:16:17 +05:30
Luis Arias 89f1d699f0 Bump jsbeautify to 1.6.2. Add support for collapse-preserve-inline brace_style for javascript. 2016-02-03 19:01:44 +01:00
Ra100 6d73fa0234 remove console.log 2016-01-28 15:43:56 +01:00
Ra100 2dce172228 add: remark for markdown 2016-01-28 13:11:09 +01:00
Ra100 b0dab1ea23 add settings to beautifier 2016-01-28 12:52:56 +01:00
Ra100 644ca188a8 Merge remote-tracking branch 'upstream/master' 2016-01-28 09:07:03 +01:00
Austin Cheney f2da1d0d29 changing default beautifier to pass unit tests 2016-01-22 16:16:10 -06:00
Austin Cheney b41bb12127 fixing a defect 2016-01-22 15:16:26 -06:00
Austin Cheney 643e695e55 fixing a defect 2016-01-22 15:15:02 -06:00
Austin Cheney 5acb264368 Updating riotjs.coffee per comment: https://github.com/Glavin001/atom-beautify/issues/750#issuecomment-174029448 2016-01-22 14:45:13 -06:00
Austin Cheney dce087c982 Merge pull request #763 from prettydiff/sld
adding support for grammar SLD
2016-01-20 04:40:36 -06:00
Austin Cheney 64579564e9 adding support for grammar SLD 2016-01-19 21:09:25 -06:00
Austin Cheney 1462d6e030 Merge pull request #756 from prettydiff/xhtml
adding XHTML file extension as an XML grammar
2016-01-18 21:15:27 -06:00
Austin Cheney 9706aec22c Merge pull request #757 from prettydiff/riotjs
Adding language Riot.js
2016-01-18 21:15:12 -06:00
Austin Cheney da68e5c397 Merge pull request #758 from prettydiff/xtemplate
Adding support for new HTML templating language: XTemplate
2016-01-18 21:14:48 -06:00
Austin Cheney 2fc91191b6 Adding support for new HTML templating language: XTemplate 2016-01-18 17:44:17 -06:00
Austin Cheney 8a34315f83 Adding language Riot.js 2016-01-18 17:33:53 -06:00
Austin Cheney 758f239241 adding XHTML file extension as an XML grammar 2016-01-18 17:18:47 -06:00
Ra100 2bc18dd601 PHPCBF support 2016-01-13 17:05:57 +01:00
Ra100 269d434a16 adding support for phpcbf (in progress) 2016-01-13 15:14:16 +01:00
Dimosthenis Kaponis ff1e875b17 Adds 'unchanged' option to the SQL beautifier for both identifiers and keywords 2016-01-13 13:57:10 +02:00
Glavin Wiechert 99299e5d30 Fixes #736. Change unformatted option default value to match js-beautify 2016-01-12 14:27:30 -04:00