Coder Social home page Coder Social logo

linter-clang's Introduction

linter-clang package

This linter plugin for Linter provides an interface to clang. It will be used with files that have the "C++", "C", "Objective-C" and "Objective-C++" syntax.

Plugin installation

Press ctrl and ',' or cmd and ',' , click on 'Packages', search 'linter clang', or:

$ apm install linter-clang

Project-specific include paths

If your project has some extra include directories, put them in a file called ".linter-clang-includes" and list them line by line. The linter will open the file and use the specified paths when linting in your project.

You can put your ".linter-clang-includes" files in subdirectories, too, the linter will find them and include the paths relative to the file they are specified in.

Project-specific compiler flags

If your project has some extra compiler flags, put them in a file called ".linter-clang-flags" and list all flags. The linter will open the file and use the specified flags when linting in your project. You can put your flag file in subdirectories, too, however, no resolving of paths will take place. For that, you can use macros (see below).

Note: Whenever there is a space in the flag file it will separate the strings before and after when passing them as arguments to the compiler (like in the command line). If you have a filename with a space, put it into quotes. Everything between quotes won't be separated. The quotes will be removed after parsing. Using quotes is therefore not supported yet (TODO: let the user put a backslash to escape the quote).

Macros

The linter will expand the following macros in your ".linter-clang-includes" and ".linter-clang-flags" files:

  • %d -> the directory of the file being linted
  • %p -> the project path
  • %% -> %

Contributing

If you would like to contribute enhancements or fixes, please do the following:

  1. Fork the plugin repository.
  2. Hack on a separate topic branch created from the latest master.
  3. Commit and push the topic branch.
  4. Make a pull request.
  5. welcome to the club

Please note that modifications should follow these coding guidelines:

  • Indent is 2 spaces.
  • Code should pass coffeelint linter.
  • Vertical whitespace helps readability, don’t be afraid to use it.

Thank you for helping out!

Other Available linters

Check out AtomLinter!

Donation

Share the love!

linter-clang's People

Contributors

aljen avatar amandacameron avatar hd-deman avatar keplersj avatar m-bra avatar maxbrunsfeld avatar quentinperez avatar snake231088 avatar

Watchers

 avatar  avatar

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.