Skip to content

Commit

Permalink
Merge pull request #58 from cs50/develop
Browse files Browse the repository at this point in the history
Disable JS until we're ready for it
  • Loading branch information
dmalan authored Nov 10, 2017
2 parents b97ee6e + 20cf37d commit 0712b27
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,5 @@
"console_scripts": ["style50=style50.__main__:main"],
},
url="https://github.com/cs50/style50",
version="2.3.3"
version="2.4.0"
)
7 changes: 5 additions & 2 deletions style50/languages.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,8 @@ def style(self, code):


class Js(C):
extensions = ["js"]
# Disable JS until we settle on a style guide for it
extensions = [] # ["js"]
magic_names = []

# Taken from http://code.activestate.com/recipes/496882-javascript-code-compression/
Expand All @@ -101,7 +102,9 @@ class Js(C):

# TODO: Determine which options, if any should be passed here
def style(self, code):
return jsbeautifier.beautify(code)
opts = jsbeautifier.default_options()
opts.end_with_newline = True
return jsbeautifier.beautify(code, opts)


class Java(C):
Expand Down

0 comments on commit 0712b27

Please sign in to comment.