Menu

#6 Add Elixir Support

v1.63
closed
nobody
None
1
2016-02-10
2014-12-06
Anonymous
No

Add support for Elixir (http://elixir-lang.org).

Has the same comment type as Ruby and CoffeeScript.

(I'm the same guy that sent patches for the CoffeeScript syntax support)

1 Attachments

Discussion

  • Al Danial

    Al Danial - 2014-12-07

    Patch applied with svn commit 419. Thanks for the contribution.

     
  • Al Danial

    Al Danial - 2014-12-07
    • status: open --> pending
     
  • Norbert

    Norbert - 2015-04-30

    I did an svn checkout and installed into $HOME/bin, but elixir files aren't recognized:

    $ touch foo.ex
    $ touch foo.exs
    $ cloc foo.ex foo.exs
           0 text files.
           0 unique files.                              
           2 files ignored.
    
    $ which cloc
    /home/nobbz/bin/cloc
    
    $ cloc --version
    1.63
    

    Even on a project with realworld files, elixir files are ignored:

    $ cloc **/*.{ex,exs}
          28 text files.
          28 unique files.                              
          28 files ignored.
    

    For exact reference the output of svn info in clocs sourcedir:

    $ LANG=C svn info
    Path: .
    Working Copy Root Path: /home/norbert/projects/sourceinstalls/cloc-code
    URL: svn://svn.code.sf.net/p/cloc/code/trunk
    Relative URL: ^/trunk
    Repository Root: svn://svn.code.sf.net/p/cloc/code
    Repository UUID: 0e9fd002-ee37-4bff-9a6e-d24515d67fd4
    Revision: 447
    Node Kind: directory
    Schedule: normal
    Last Changed Author: alnd
    Last Changed Rev: 447
    Last Changed Date: 2015-04-19 01:29:04 +0200 (So, 19 Apr 2015)
    
     
  • Al Danial

    Al Danial - 2015-05-01

    Regarding the zero-sized files created with touch, cloc will always ignore those (ref the explanation with the --ignored=reason.txt option).

    To get some real Elixir code I downloaded
    https://github.com/elixir-lang/elixir/archive/master.zip using the
    "Download ZIP" button at https://github.com/elixir-lang/elixir then
    ran cloc against the zip file:

    ./cloc elixir-master.zip 
         461 text files.
         461 unique files.                                          
          38 files ignored.
    
    http://cloc.sourceforge.net v 1.63  T=2.74 s (156.8 files/s, 32983.9 lines/s)
    -------------------------------------------------------------------------------
    Language                     files          blank        comment           code
    -------------------------------------------------------------------------------
    Elixir                         368          16300           2504          61720
    Erlang                          48           1725            516           7042
    make                             1             49             13            174
    Bourne Shell                     3             19              1            161
    DOS Batch                        4             11             15            110
    ASP.Net                          4              6              0             44
    PowerShell                       1              2              3             18
    YAML                             1              6              0             15
    -------------------------------------------------------------------------------
    SUM:                           430          18118           3052          69284
    -------------------------------------------------------------------------------
    

    Can you try with the same zip file? Alternatively, could you post one or more of your .ex and/or .exs files?

     
  • Al Danial

    Al Danial - 2015-06-27

    v1.64 released

     
  • Al Danial

    Al Danial - 2015-06-27
    • status: pending --> closed
     
  • Anonymous

    Anonymous - 2016-02-10
    Post awaiting moderation.

Anonymous
Anonymous

Add attachments
Cancel





Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.