GithubHelp home page GithubHelp logo

erl_unused_includes's Introduction

erl_unused_includes.sh

Copyright (C) 2014 Klarna AB.

This is a shell script that can be used as a wrapper for the Erlang erlc compiler, that eliminates unnecessary include declarations from the source files by compiling the file multiple times and only keeping those include declarations that are actually necessary for the compilation to work.

The script takes the same parameters as erlc, except for an extra initial parameter which is the path to the real erlc. E.g.: erl_unused_includes.sh erlc -o ebin foo.erl. Should work with any erlc command line.

If you are using Make and you have a configuration variable that specifies which erlc to use, e.g.:

ERLC=/path/to/erlc

then you should be able to simply plug in this script instead, in order to run it on all your .erl files:

ERLC=/path/to/erl_unused_includes.sh /path/to/erlc

Just run make clean && make and your source files will get cleaned up.

Available under the MIT License (see LICENSE).

erl_unused_includes's People

Contributors

richcarl 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.