Skip to content

Update to latest Bitbucket API; simplify validation; add logging and helpful response - #9

Open
matmar10 wants to merge 4 commits into
chesleybrown:masterfrom
QulinaryOrg:master
Open

Update to latest Bitbucket API; simplify validation; add logging and helpful response#9
matmar10 wants to merge 4 commits into
chesleybrown:masterfrom
QulinaryOrg:master

Conversation

@matmar10

Copy link
Copy Markdown

No description provided.

@chesleybrown

Copy link
Copy Markdown
Owner

This looks good. However, you have a mix of tabs/space indentation. The project should be done in tab indentation. If you fix this, I will merge in.

@chesleybrown

Copy link
Copy Markdown
Owner

I've improved some of the logging functionality in #10, along with adding code style verification and updating outdated deps. Feel free to apply your additional parameter verifications on top of the latest of master.

@matmar10

Copy link
Copy Markdown
Author

I wish you'd just copied and replaced spaces with tabs before your latest pull request. Now there are lots and lots of merge conflicts now. I feel like my work was wasted :-P

Regarding "code style verification" I see your tabs4life but it seems it lacks a style guide? Can you provide a .jsbeautifyrc so that those of us who don't yet know your "very opinionated" personal preference can let our editors do the heavy lifting?

@chesleybrown

Copy link
Copy Markdown
Owner

Ah crap, you're right. I should have merged this in first. Sorry. I can apply your express validate additions later if you don't have the time. Just let me know.

I will look into editor integration with tabs4life as well.

@chesleybrown

Copy link
Copy Markdown
Owner

Not sure if you saw, but bit bucket recently released native build status integration. Although I don't think Codeship has updated to support it yet.

https://blog.bitbucket.org/2015/11/18/introducing-the-build-status-api-for-bitbucket-cloud/

@matmar10

Copy link
Copy Markdown
Author

No worries. Actually JSBeautify has a grunt plugin that would work well for this purpose (no IDE integration needed). One of the build steps would format according to your guideline. Here's an example of how it can be done:

https://github.com/matmar10/grunt-env-config-to-file/blob/master/Gruntfile.js

Need your tweaks to make this work, but this is the general idea for a .jsbeautifyrc config:

{
  "js": {
    "allowed_file_extensions": ["js", "json", "jshintrc", "jsbeautifyrc"],
    "brace_style": "end-expand",
    "break_chained_methods": true,
    "e4x": false,
    "end_with_newline": true,
    "indent_char": "\t",
    "indent_level": 0,
    "indent_size": 1,
    "indent_with_tabs": true,
    "jslint_happy": true,
    "keep_array_indentation": false,
    "keep_function_indentation": false,
    "max_preserve_newlines": 3,
    "preserve_newlines": true,
    "space_after_anon_function": true,
    "space_before_conditional": true,
    "space_in_empty_paren": false,
    "space_in_paren": false,
    "unescape_strings": false,
    "wrap_line_length": 120
  }
}

@chesleybrown

Copy link
Copy Markdown
Owner

I've also been looking at http://eslint.org as well which has a similar .eslintrc type configuration file. Haven't had time to update my grunt-tabs4life to use it yet though.

In the meantime, you can run npm test which will print out any lint errors.

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.

2 participants