Giter Club home page Giter Club logo

github-editorconfig's Introduction

github-editorconfig

DEPRECATED: as of 08-Jun-2015, Github added native support for EditorConfig.

This is a browser extension that provides EditorConfig support for GitHub.

Download links

You can download extension for your browser from the corresponding store:

Description

Extension looks for .editorconfig files in the repository the current file belongs to, and applies it's settings to code viewer and editor. Branch is always taken into account.

On options page you can also set default editorconfig.

You can test extension on files in demo folder of this repo.

Extension is built with Kango - cross-browser extension framework.

Screenshots

Sample .editorconfig:

Sample .editorconfig

Code viewer (tabs are set to preconfigured width of 4 instead of GitHub's default 8):

Code viewer

Code editor (preconfigured options are chosen and marked as (auto); trim_trailing_whitespace and insert_final_newline are taken into account on commit):

Code editor

Options page (just a default .editorconfig):

Options page (default editorconfig)

github-editorconfig's People

Contributors

jednano avatar rreverser avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

github-editorconfig's Issues

Are editorconfig files applied over the defaults?

If an .editorconfig file were found, would it apply those changes over the defaults or just on their own? For example, if the default tab_width was 4 and I have an .editorconfig file with trim_trailing_whitespace = true, is it going to also inherit the default tab_width of 4?

Furthermore, what do you do in cases where there are multiple .editorconfig files in the project? There can be more than one and they all may or may not have root = true.

Tab formatting not applied in revision comparison view

I've recently tried this plug-in (github's native support doesn't seem to work for us) as we were trying to change the way GtHub displays tab sizes. I created a stackoverflow question (http://stackoverflow.com/questions/33892410/editorconfig-file-in-github/) and it was suggested I mentioned this here.

I created an .editorconfig file which I stuck at our repo's root:

# top-most EditorConfig file
root = true

#4 space indentation
[*.{cpp,h,cs,xaml,editorconfig}]
indent_style = space
indent_size = 4

This works great if we go look at a file in GitHub, however if we are looking at the revision comparison view (such as when going through a pull request review) the tabs still display in their original 8 spaces. I'm not sure if this is a known limitation, or if it just isn't working for us, but for us this is the main reason we got excited about this tool and it was a bit sad to see it didn't work.

Thanks, and any information on this would be welcome!

List supported properties/functionality in README file

Does this plugin only support indentation (in both view and edit mode)?

If so indent_style/indent_size (and possibly tab_width) should be listed as supported in the README file (similar to the way the other plugins list support).

Don't apply to the code viewer

The code viewer is for viewing code and I don't think the repo project should decide how I view its code.

Applying to the editor makes sense, but for the code viewer it should be some default values. Might add an option page to change them. The code viewer should not be affected by the .editorconfig config.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.