title: maven external jar dependency
body: <p>I am trying to use a jar given by my teacher in my code. So I placed the jar in a lib directory in my project and ran this command :</p>
  
  <pre><code>mvn install:install-file -Dfile=lib/IDLogger.jar -DgroupId=IDLogger -DartifactId=IDLogger -Dversion=1.0 -Dpackaging=jar
  </code></pre>
  
  <p>Everything is fine.</p>
  
  <p>Then I add the dependency to the pom : </p>
  
  <pre><code>&lt;dependency&gt;
     &lt;groupId&gt;IDLogger&lt;/groupId&gt;
     &lt;artifactId&gt;IDLogger&lt;/artifactId&gt;
     &lt;version&gt;1.0&lt;/version&gt;
     &lt;scope&gt;compile&lt;/scope&gt;
  &lt;/dependency&gt;
  </code></pre>
  
  <p>But then when I try to use the jar, the compilation fails and tells me that the symbol(the class) can't be found. I even tried adding an import statement : </p>
  
  <pre><code>import IDLogger.IDLogger;
  </code></pre>
  
  <p>but it tells me that there is no such package. </p>
  
  <p>How can I use this jar in my code in maven?</p>
  
  <p>This is the code :</p>
  
  <pre><code>IDLogger logger = IDLogger.getInstance(); 
  
  ...
  
  logger.logID(id); 
  </code></pre>
  
  <p>I get the symbol <code>IDLogger</code> not found error </p>
  
  <p>This is as much as I know about this custom jar...</p>