├── .gitignore
├── .travis.yml
├── README.md
├── pom.xml
└── sonar-elixir-plugin
├── pom.xml
└── src
├── main
└── java
│ └── eu
│ └── arthepsy
│ └── sonar
│ └── plugins
│ └── elixir
│ ├── ElixirConfiguration.java
│ ├── ElixirPlugin.java
│ ├── language
│ ├── Elixir.java
│ ├── ElixirMeasureSensor.java
│ └── ElixirParser.java
│ └── rule
│ └── ElixirQualityProfile.java
└── test
├── java
└── eu
│ └── arthepsy
│ └── sonar
│ └── plugins
│ └── elixir
│ ├── ElixirConfigurationTest.java
│ ├── ElixirPluginTest.java
│ ├── language
│ ├── ElixirMeasureSensorTest.java
│ └── ElixirTest.java
│ ├── rule
│ └── ElixirQualityProfileTest.java
│ └── util
│ └── ClassDefinition.java
└── resources
└── test_doc.ex
/.gitignore:
--------------------------------------------------------------------------------
1 | target/
2 |
3 | # IntelliJ IDEA
4 | *.iws
5 | *.iml
6 | *.ipr
7 | .idea/
8 |
9 | # Eclipse
10 | .classpath
11 | .project
12 | .settings
13 |
14 |
--------------------------------------------------------------------------------
/.travis.yml:
--------------------------------------------------------------------------------
1 | ---
2 | language: java
3 | jdk:
4 | - openjdk7
5 | - oraclejdk7
6 | - oraclejdk8
7 |
8 | after_success:
9 | - mvn clean test jacoco:report coveralls:report
10 |
11 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | SonarQube Elixir Plugin
2 | ===========
3 | [](https://travis-ci.org/arthepsy/sonar-elixir/)
4 | [](https://coveralls.io/r/arthepsy/sonar-elixir?branch=master)
5 |
6 |
--------------------------------------------------------------------------------
/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 | 4.0.0
6 |
7 |
8 | org.codehaus.sonar-plugins
9 | parent
10 | 19
11 |
12 |
13 |
14 | sonar-elixir-plugin
15 |
16 |
17 | eu.arthepsy.sonar.plugins
18 | elixir
19 | 1.0-SNAPSHOT
20 | pom
21 |
22 | SonarQube Elixir
23 |
24 |
25 | ${dev.name}
26 |
27 |
28 |
29 | MIT
30 | http://opensource.org/licenses/MIT
31 |
32 |
33 |
34 |
35 | ${dev.nick}
36 | ${dev.name}
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 | scm:git:
45 | scm:git:
46 |
47 | HEAD
48 |
49 |
50 |
51 | arthepsy
52 | Andris Raugulis
53 | moo@arthepsy.eu
54 | 4.5
55 | {0,date,yyyy-MM-dd HH:mm:ssa}
56 | UTF-8
57 |
58 |
59 |
60 |
61 |
62 | org.codehaus.sonar
63 | sonar-plugin-api
64 | ${sonar.version}
65 | provided
66 |
67 |
68 | org.codehaus.sonar
69 | sonar-core
70 | ${sonar.version}
71 | provided
72 |
73 |
74 |
75 | org.codehaus.sonar
76 | sonar-testing-harness
77 | ${sonar.version}
78 | test
79 |
80 |
81 | org.mockito
82 | mockito-all
83 | 1.10.19
84 | test
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 | org.apache.maven.plugins
94 | maven-compiler-plugin
95 | 3.3
96 |
97 |
98 | -Xlint:unchecked
99 | -Xlint:deprecation
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 | org.jacoco
108 | jacoco-maven-plugin
109 | 0.7.5.201505241946
110 |
111 |
112 | prepare-agent
113 |
114 | prepare-agent
115 |
116 |
117 |
118 |
119 |
120 | org.eluder.coveralls
121 | coveralls-maven-plugin
122 | 3.1.0
123 |
124 |
125 |
126 | com.mycila.maven-license-plugin
127 | maven-license-plugin
128 | 1.9.0
129 |
130 | org/sonar/plugins/licenseheaders/MIT.txt
131 |
132 | 2015
133 | ${dev.name}
134 | ${dev.mail}
135 |
136 |
137 |
138 |
139 |
140 |
141 |
142 |
--------------------------------------------------------------------------------
/sonar-elixir-plugin/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 | 4.0.0
6 |
7 |
8 | eu.arthepsy.sonar.plugins
9 | elixir
10 | 1.0-SNAPSHOT
11 |
12 |
13 | eu.arthepsy.sonar.plugins
14 | sonar-elixir-plugin
15 | 1.0-SNAPSHOT
16 | sonar-plugin
17 |
18 | SonarQube Elixir plugin
19 | Enables analysis of JavaScript projects.
20 |
21 |
22 | eu.arthepsy.sonar.plugins.elixir.ElixirPlugin
23 |
24 |
25 |
26 |
27 | org.codehaus.sonar
28 | sonar-plugin-api
29 |
30 |
31 | org.codehaus.sonar
32 | sonar-core
33 |
34 |
35 |
36 | org.codehaus.sonar
37 | sonar-testing-harness
38 | test
39 |
40 |
41 | org.mockito
42 | mockito-all
43 |
44 |
45 |
46 |
47 |
48 |
49 | org.apache.maven.plugins
50 | maven-compiler-plugin
51 |
52 |
53 |
54 |
55 |
56 |
--------------------------------------------------------------------------------
/sonar-elixir-plugin/src/main/java/eu/arthepsy/sonar/plugins/elixir/ElixirConfiguration.java:
--------------------------------------------------------------------------------
1 | /*
2 | * SonarQube Elixir plugin
3 | * Copyright (C) 2015 Andris Raugulis
4 | * moo@arthepsy.eu
5 | *
6 | * Permission is hereby granted, free of charge, to any person obtaining a copy
7 | * of this software and associated documentation files (the "Software"), to deal
8 | * in the Software without restriction, including without limitation the rights
9 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10 | * copies of the Software, and to permit persons to whom the Software is
11 | * furnished to do so, subject to the following conditions:
12 | *
13 | * The above copyright notice and this permission notice shall be included in
14 | * all copies or substantial portions of the Software.
15 | *
16 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22 | * THE SOFTWARE.
23 | */
24 | package eu.arthepsy.sonar.plugins.elixir;
25 |
26 | import com.google.common.collect.ImmutableList;
27 | import org.sonar.api.config.PropertyDefinition;
28 |
29 | import java.util.List;
30 |
31 | public final class ElixirConfiguration {
32 | public static final String LOG_PREFIX = "[elixir] ";
33 |
34 | public static List getPropertyDefinitions() {
35 | ImmutableList.Builder properties = ImmutableList.builder();
36 | return properties.build();
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/sonar-elixir-plugin/src/main/java/eu/arthepsy/sonar/plugins/elixir/ElixirPlugin.java:
--------------------------------------------------------------------------------
1 | /*
2 | * SonarQube Elixir plugin
3 | * Copyright (C) 2015 Andris Raugulis
4 | * moo@arthepsy.eu
5 | *
6 | * Permission is hereby granted, free of charge, to any person obtaining a copy
7 | * of this software and associated documentation files (the "Software"), to deal
8 | * in the Software without restriction, including without limitation the rights
9 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10 | * copies of the Software, and to permit persons to whom the Software is
11 | * furnished to do so, subject to the following conditions:
12 | *
13 | * The above copyright notice and this permission notice shall be included in
14 | * all copies or substantial portions of the Software.
15 | *
16 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22 | * THE SOFTWARE.
23 | */
24 | package eu.arthepsy.sonar.plugins.elixir;
25 |
26 | import com.google.common.collect.ImmutableList;
27 | import eu.arthepsy.sonar.plugins.elixir.language.Elixir;
28 | import eu.arthepsy.sonar.plugins.elixir.language.ElixirMeasureSensor;
29 | import eu.arthepsy.sonar.plugins.elixir.rule.ElixirQualityProfile;
30 | import org.sonar.api.SonarPlugin;
31 |
32 | import java.util.List;
33 |
34 | public class ElixirPlugin extends SonarPlugin {
35 |
36 | @Override
37 | public List getExtensions() {
38 | ImmutableList.Builder