You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Apache Omega <ja...@yahoo.com> on 2011/12/18 20:14:20 UTC

having problems with java -cp taget command

I've worked out some kinks just to find another kink
i entered (java -cp target/MavenTestApp-1.0-SNAPSHOT.jar
org.JasnThomas.ShadowInnovations) and the message i got was could not find
or load main class org.JasonThomas.ShadowInnovations  and the folder is
clearly in the right path
src/main/java/org/JasonThomas/ShadowInnovations/App.java

how is this possible when the folder is clearly there

p.s. sorry i'm posting so much I'm just trying to get started quickly -
losing time on actually programing messing around with all this but i gotta
learn it.


--
View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084317.html
Sent from the Maven - Users mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: having problems with java -cp taget command

Posted by Matt Narrell <ma...@gmail.com>.
Where is the code?

On Dec 18, 2011, at 2:46 PM, Apache Omega <ja...@yahoo.com> wrote:

> yes its in there I'm just totally confused right now hers everything i did
>
> when I run java -cp target\TestAppTest-1.0-SNAPSHOT.jar
> (and then)org.jason.ShadowInnovations.App (that didnt work [Error: Could not find or load main class jar] so I put
> in)org.jason.ShadowInnovations.AppTest (and i got [Error: Could not find or load main class]
>
> but this is in my POM
> - <project xmlns="http://maven.apache.org/POM/4.0.0"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
> http://maven.apache.org/xsd/maven-4.0.0.xsd">
> <modelVersion>4.0.0</modelVersion>
> <groupId>org.jason.ShadowInnovations</groupId>
> <artifactId>TestAppTest</artifactId>
> <version>1.0-SNAPSHOT</version>
> <packaging>jar</packaging>
> <name>TestAppTest</name>
> <url>http://maven.apache.org</url>
> - <properties>
> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
> </properties>
> - <dependencies>
> - <dependency>
> <groupId>junit</groupId>
> <artifactId>junit</artifactId>
> <version>3.8.1</version>
> <scope>test</scope>
> </dependency>
> </dependencies>
> </project>
>
> This is my code****************************************
>
>
> -------------------------------------------------------
> T E S T S
> -------------------------------------------------------
> Running org.jason.ShadowInnovations.AppTest
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.015 sec
>
> Results :
>
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0
>
> [INFO]
> [INFO] --- maven-jar-plugin:2.3.1:jar (default-jar) @ TestAppTest ---
> [INFO] Building jar: C:\Program Files\apache-maven-3.0.3\my-app\stupid\TestAppTe
> st\target\TestAppTest-1.0-SNAPSHOT.jar
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 2.798s
> [INFO] Finished at: Sun Dec 18 16:03:33 CST 2011
> [INFO] Final Memory: 11M/104M
> [INFO] ------------------------------------------------------------------------
> C:\Program Files\apache-maven-3.0.3\my-app\stupid\TestAppTest>java -cp target\Te
> stAppTest-1.0-SNAPSHOT. jar org.jason.ShadowInnovations.App
> Error: Could not find or load main class jar
>
>
>
> C:\Program Files\apache-maven-3.0.3\my-app\stupid\TestAppTest>java -cp target\Te
> stAppTest-1.0-SNAPSHOT.jar org.jason.ShadowInnovations.AppTest
> Error: Could not find or load main class org.jason.ShadowInnovations.AppTest
>
> C:\Program Files\apache-maven-3.0.3\my-app\stupid\TestAppTest>
>
>
> ________________________________
> From: Matt Narrell [via Maven] <ml...@n5.nabble.com>
> To: Apache Omega <ja...@yahoo.com>
> Sent: Sunday, December 18, 2011 3:34 PM
> Subject: Re: having problems with java -cp taget command
>
>
> Is this class in your jar?
>
> On Dec 18, 2011, at 1:02 PM, Apache Omega <[hidden email]> wrote:
>
>
>> with 'o'
>>
>>
>>
>> ________________________________
>> From: Robert Scholte [via Maven] <[hidden email]>
>> To: Apache Omega <[hidden email]>
>> Sent: Sunday, December 18, 2011 2:21 PM
>> Subject: RE: having problems with java -cp taget command
>>
>>
>>
>> Is Jason with or without 'o'?
>>
>>
>>
>>
>>> Date: Sun, 18 Dec 2011 12:15:53 -0800
>>> From: [hidden email]
>>> To: [hidden email]
>>> Subject: Re: having problems with java -cp taget command
>>>
>>> I tried it again and it still gives me the same error I copied the code and this is what it says
>>>
>>> I just don't understand this problem
>>>
>>> -------------------------------------------------------
>>> T E S T S
>>> -------------------------------------------------------
>>> Running org.JasonThomas.ShadowInnovations.AppTest
>>> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.013 sec
>>>
>>> Results :
>>>
>>> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0
>>>
>>> [INFO]
>>> [INFO] --- maven-jar-plugin:2.3.1:jar (default-jar) @ MavenTest ---
>>> [INFO] Building jar: C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest\
>>> target\MavenTest-1.0-SNAPSHOT.jar
>>> [INFO] ------------------------------------------------------------------------
>>> [INFO] BUILD SUCCESS
>>> [INFO] ------------------------------------------------------------------------
>>> [INFO] Total time: 3.000s
>>> [INFO] Finished at: Sun Dec 18 14:10:07 CST 2011
>>> [INFO] Final Memory: 12M/104M
>>> [INFO] ------------------------------------------------------------------------
>>> C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest>java -cp target/Maven
>>> Test-1.0-SNAPSHOT.jar org.JasonThomas.ShadowInnovations
>>> Error: Could not find or load main class org.JasonThomas.ShadowInnovations
>>>
>>> C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest>
>>>
>>>
>>>
>>> ________________________________
>>> From: Robert Scholte [via Maven] <[hidden email]>
>>> To: Apache Omega <[hidden email]>
>>> Sent: Sunday, December 18, 2011 1:21 PM
>>> Subject: RE: having problems with java -cp taget command
>>>
>>>
>>>
>>>
>>> This problem has nothing to do with Maven, it's java basics.
>>>
>>> First of all, you shouldn't look under src/main/java, this is not on the classpath. You should look in the jar.
>>>
>>> The real problem is a typo:
>>>
>>> org.JasnThomas.ShadowInnovations
>>>
>>> org.JasonThomas.ShadowInnovations
>>>
>>>
>>>
>>> see the difference?
>>>
>>>
>>>
>>> -Robert
>>>
>>>
>>>
>>> ps. try to keep packagenames lowercase.
>>>
>>>
>>>
>>>> Date: Sun, 18 Dec 2011 11:14:20 -0800
>>>> From: [hidden email]
>>>> To: [hidden email]
>>>> Subject: having problems with java -cp taget command
>>>>
>>>> I've worked out some kinks just to find another kink
>>>> i entered (java -cp target/MavenTestApp-1.0-SNAPSHOT.jar
>>>> org.JasnThomas.ShadowInnovations) and the message i got was could not find
>>>> or load main class org.JasonThomas.ShadowInnovations and the folder is
>>>> clearly in the right path
>>>> src/main/java/org/JasonThomas/ShadowInnovations/App.java
>>>>
>>>> how is this possible when the folder is clearly there
>>>>
>>>> p.s. sorry i'm posting so much I'm just trying to get started quickly -
>>>> losing time on actually programing messing around with all this but i gotta
>>>> learn it.
>>>>
>>>>
>>>> --
>>>> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084317.html
>>>> Sent from the Maven - Users mailing list archive at Nabble.com.
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: [hidden email]
>>>> For additional commands, e-mail: [hidden email]
>>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: [hidden email]
>>> For additional commands, e-mail: [hidden email]
>>>
>>>
>>>
>>> ________________________________
>>>
>>> If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084324.html
>>> To unsubscribe from having problems with java -cp taget command, click here.
>>> NAML
>>>
>>> --
>>> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084424.html
>>> Sent from the Maven - Users mailing list archive at Nabble.com.                         ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [hidden email]
>> For additional commands, e-mail: [hidden email]
>>
>>
>>
>> ________________________________
>>
>> If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084433.html
>> To unsubscribe from having problems with java -cp taget command, click here.
>> NAML
>>
>> --
>> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084499.html
>> Sent from the Maven - Users mailing list archive at Nabble.com.
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>
>
> ________________________________
>
> If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084553.html
> To unsubscribe from having problems with java -cp taget command, click here.
> NAML
>
> --
> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084671.html
> Sent from the Maven - Users mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: having problems with java -cp taget command

Posted by Apache Omega <ja...@yahoo.com>.
thank you
I'm going to research on the proxy subject 

I didnt know learning all this would be so difficult. I'm just a junior in college just getting past C++ and Java
but I now my proxy is in settings so I think i'm in the right direction

thanks again!!!



________________________________
 From: Wayne Fay [via Maven] <ml...@n5.nabble.com>
To: Apache Omega <ja...@yahoo.com> 
Sent: Sunday, December 18, 2011 10:24 PM
Subject: Re: having problems with java -cp taget command
 

> Running org.jason.ShadowInnovations.AppTest 
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.015 sec 
... 
> when I run java -cp target\TestAppTest-1.0-SNAPSHOT.jar 
> (and then)org.jason.ShadowInnovations.App (that didnt work [Error: Could not find or load main class jar] so I put 
> in)org.jason.ShadowInnovations.AppTest (and i got [Error: Could not find or load main class] 

Maven does not package your test files into the primary project 
artifact. Thus you will not get java -jar xyz.jar blah.AppTest to work 
without additional configuration in the pom file. 

Wayne 

--------------------------------------------------------------------- 
To unsubscribe, e-mail: [hidden email] 
For additional commands, e-mail: [hidden email] 



________________________________
 
If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5085064.html 
To unsubscribe from having problems with java -cp taget command, click here.
NAML 

--
View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5085115.html
Sent from the Maven - Users mailing list archive at Nabble.com.

Re: having problems with java -cp taget command

Posted by Wayne Fay <wa...@gmail.com>.
> Running org.jason.ShadowInnovations.AppTest
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.015 sec
...
> when I run java -cp target\TestAppTest-1.0-SNAPSHOT.jar
> (and then)org.jason.ShadowInnovations.App (that didnt work [Error: Could not find or load main class jar] so I put
> in)org.jason.ShadowInnovations.AppTest (and i got [Error: Could not find or load main class]

Maven does not package your test files into the primary project
artifact. Thus you will not get java -jar xyz.jar blah.AppTest to work
without additional configuration in the pom file.

Wayne

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: having problems with java -cp taget command

Posted by Barrie Treloar <ba...@gmail.com>.
On Mon, Dec 19, 2011 at 9:40 AM, Wayne Fay <wa...@gmail.com> wrote:
>> when I run java -cp target\TestAppTest-1.0-SNAPSHOT.jar
>> (and then)org.jason.ShadowInnovations.App (that didnt work [Error: Could not
>> find or load main class jar] so I put
>> in)org.jason.ShadowInnovations.AppTest (and i got [Error: Could not find or
>> load main class]
>
> You should go download Eclipse or Netbeans and let your IDE handle the
> basics for you, then worry about these details once you're more
> comfortable with how things work. Both IDEs are free and have Maven
> plug-ins for building projects.

Also, it looks like fundamentally Maven is doing the right thing.
What you are stumbling into are Java basics and you are going to
struggle to get advice from this list.
Ask at local Java expert at your company or find someone and pay them
to train you.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: having problems with java -cp taget command

Posted by Wayne Fay <wa...@gmail.com>.
> when I run java -cp target\TestAppTest-1.0-SNAPSHOT.jar
> (and then)org.jason.ShadowInnovations.App (that didnt work [Error: Could not
> find or load main class jar] so I put
> in)org.jason.ShadowInnovations.AppTest (and i got [Error: Could not find or
> load main class]

You should go download Eclipse or Netbeans and let your IDE handle the
basics for you, then worry about these details once you're more
comfortable with how things work. Both IDEs are free and have Maven
plug-ins for building projects.

Wayne

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: having problems with java -cp taget command

Posted by Apache Omega <ja...@yahoo.com>.
yes its in there I'm just totally confused right now hers everything i did

when I run java -cp target\TestAppTest-1.0-SNAPSHOT.jar 
(and then)org.jason.ShadowInnovations.App (that didnt work [Error: Could not find or load main class jar] so I put 
in)org.jason.ShadowInnovations.AppTest (and i got [Error: Could not find or load main class]

but this is in my POM
- <project xmlns="http://maven.apache.org/POM/4.0.0" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion> 
<groupId>org.jason.ShadowInnovations</groupId> 
<artifactId>TestAppTest</artifactId> 
<version>1.0-SNAPSHOT</version> 
<packaging>jar</packaging> 
<name>TestAppTest</name> 
<url>http://maven.apache.org</url> 
- <properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> 
</properties>
- <dependencies>
- <dependency>
<groupId>junit</groupId> 
<artifactId>junit</artifactId> 
<version>3.8.1</version> 
<scope>test</scope> 
</dependency>
</dependencies>
</project>

This is my code****************************************


-------------------------------------------------------
T E S T S
-------------------------------------------------------
Running org.jason.ShadowInnovations.AppTest
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.015 sec

Results :

Tests run: 1, Failures: 0, Errors: 0, Skipped: 0

[INFO]
[INFO] --- maven-jar-plugin:2.3.1:jar (default-jar) @ TestAppTest ---
[INFO] Building jar: C:\Program Files\apache-maven-3.0.3\my-app\stupid\TestAppTe
st\target\TestAppTest-1.0-SNAPSHOT.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.798s
[INFO] Finished at: Sun Dec 18 16:03:33 CST 2011
[INFO] Final Memory: 11M/104M
[INFO] ------------------------------------------------------------------------
C:\Program Files\apache-maven-3.0.3\my-app\stupid\TestAppTest>java -cp target\Te
stAppTest-1.0-SNAPSHOT. jar org.jason.ShadowInnovations.App
Error: Could not find or load main class jar



C:\Program Files\apache-maven-3.0.3\my-app\stupid\TestAppTest>java -cp target\Te
stAppTest-1.0-SNAPSHOT.jar org.jason.ShadowInnovations.AppTest
Error: Could not find or load main class org.jason.ShadowInnovations.AppTest

C:\Program Files\apache-maven-3.0.3\my-app\stupid\TestAppTest>


________________________________
 From: Matt Narrell [via Maven] <ml...@n5.nabble.com>
To: Apache Omega <ja...@yahoo.com> 
Sent: Sunday, December 18, 2011 3:34 PM
Subject: Re: having problems with java -cp taget command
 

Is this class in your jar? 

On Dec 18, 2011, at 1:02 PM, Apache Omega <[hidden email]> wrote: 


> with 'o' 
> 
> 
> 
> ________________________________ 
> From: Robert Scholte [via Maven] <[hidden email]> 
> To: Apache Omega <[hidden email]> 
> Sent: Sunday, December 18, 2011 2:21 PM 
> Subject: RE: having problems with java -cp taget command 
> 
> 
> 
> Is Jason with or without 'o'? 
> 
> 
> 
> 
>> Date: Sun, 18 Dec 2011 12:15:53 -0800 
>> From: [hidden email] 
>> To: [hidden email] 
>> Subject: Re: having problems with java -cp taget command 
>> 
>> I tried it again and it still gives me the same error I copied the code and this is what it says 
>> 
>> I just don't understand this problem 
>> 
>> ------------------------------------------------------- 
>> T E S T S 
>> ------------------------------------------------------- 
>> Running org.JasonThomas.ShadowInnovations.AppTest 
>> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.013 sec 
>> 
>> Results : 
>> 
>> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0 
>> 
>> [INFO] 
>> [INFO] --- maven-jar-plugin:2.3.1:jar (default-jar) @ MavenTest --- 
>> [INFO] Building jar: C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest\ 
>> target\MavenTest-1.0-SNAPSHOT.jar 
>> [INFO] ------------------------------------------------------------------------ 
>> [INFO] BUILD SUCCESS 
>> [INFO] ------------------------------------------------------------------------ 
>> [INFO] Total time: 3.000s 
>> [INFO] Finished at: Sun Dec 18 14:10:07 CST 2011 
>> [INFO] Final Memory: 12M/104M 
>> [INFO] ------------------------------------------------------------------------ 
>> C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest>java -cp target/Maven 
>> Test-1.0-SNAPSHOT.jar org.JasonThomas.ShadowInnovations 
>> Error: Could not find or load main class org.JasonThomas.ShadowInnovations 
>> 
>> C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest> 
>> 
>> 
>> 
>> ________________________________ 
>> From: Robert Scholte [via Maven] <[hidden email]> 
>> To: Apache Omega <[hidden email]> 
>> Sent: Sunday, December 18, 2011 1:21 PM 
>> Subject: RE: having problems with java -cp taget command 
>> 
>> 
>> 
>> 
>> This problem has nothing to do with Maven, it's java basics. 
>> 
>> First of all, you shouldn't look under src/main/java, this is not on the classpath. You should look in the jar. 
>> 
>> The real problem is a typo: 
>> 
>> org.JasnThomas.ShadowInnovations 
>> 
>> org.JasonThomas.ShadowInnovations 
>> 
>> 
>> 
>> see the difference? 
>> 
>> 
>> 
>> -Robert 
>> 
>> 
>> 
>> ps. try to keep packagenames lowercase. 
>> 
>> 
>> 
>>> Date: Sun, 18 Dec 2011 11:14:20 -0800 
>>> From: [hidden email] 
>>> To: [hidden email] 
>>> Subject: having problems with java -cp taget command 
>>> 
>>> I've worked out some kinks just to find another kink 
>>> i entered (java -cp target/MavenTestApp-1.0-SNAPSHOT.jar 
>>> org.JasnThomas.ShadowInnovations) and the message i got was could not find 
>>> or load main class org.JasonThomas.ShadowInnovations and the folder is 
>>> clearly in the right path 
>>> src/main/java/org/JasonThomas/ShadowInnovations/App.java 
>>> 
>>> how is this possible when the folder is clearly there 
>>> 
>>> p.s. sorry i'm posting so much I'm just trying to get started quickly - 
>>> losing time on actually programing messing around with all this but i gotta 
>>> learn it. 
>>> 
>>> 
>>> -- 
>>> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084317.html
>>> Sent from the Maven - Users mailing list archive at Nabble.com. 
>>> 
>>> --------------------------------------------------------------------- 
>>> To unsubscribe, e-mail: [hidden email] 
>>> For additional commands, e-mail: [hidden email] 
>>> --------------------------------------------------------------------- 
>> To unsubscribe, e-mail: [hidden email] 
>> For additional commands, e-mail: [hidden email] 
>> 
>> 
>> 
>> ________________________________ 
>> 
>> If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084324.html
>> To unsubscribe from having problems with java -cp taget command, click here. 
>> NAML 
>> 
>> -- 
>> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084424.html
>> Sent from the Maven - Users mailing list archive at Nabble.com.                         --------------------------------------------------------------------- 
> To unsubscribe, e-mail: [hidden email] 
> For additional commands, e-mail: [hidden email] 
> 
> 
> 
> ________________________________ 
> 
> If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084433.html
> To unsubscribe from having problems with java -cp taget command, click here. 
> NAML 
> 
> -- 
> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084499.html
> Sent from the Maven - Users mailing list archive at Nabble.com. 
--------------------------------------------------------------------- 
To unsubscribe, e-mail: [hidden email] 
For additional commands, e-mail: [hidden email] 



________________________________
 
If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084553.html 
To unsubscribe from having problems with java -cp taget command, click here.
NAML

--
View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084671.html
Sent from the Maven - Users mailing list archive at Nabble.com.

Re: having problems with java -cp taget command

Posted by Matt Narrell <ma...@gmail.com>.
Is this class in your jar?

On Dec 18, 2011, at 1:02 PM, Apache Omega <ja...@yahoo.com> wrote:

> with 'o'
>
>
>
> ________________________________
> From: Robert Scholte [via Maven] <ml...@n5.nabble.com>
> To: Apache Omega <ja...@yahoo.com>
> Sent: Sunday, December 18, 2011 2:21 PM
> Subject: RE: having problems with java -cp taget command
>
>
>
> Is Jason with or without 'o'?
>
>
>
>
>> Date: Sun, 18 Dec 2011 12:15:53 -0800
>> From: [hidden email]
>> To: [hidden email]
>> Subject: Re: having problems with java -cp taget command
>>
>> I tried it again and it still gives me the same error I copied the code and this is what it says
>>
>> I just don't understand this problem
>>
>> -------------------------------------------------------
>> T E S T S
>> -------------------------------------------------------
>> Running org.JasonThomas.ShadowInnovations.AppTest
>> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.013 sec
>>
>> Results :
>>
>> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0
>>
>> [INFO]
>> [INFO] --- maven-jar-plugin:2.3.1:jar (default-jar) @ MavenTest ---
>> [INFO] Building jar: C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest\
>> target\MavenTest-1.0-SNAPSHOT.jar
>> [INFO] ------------------------------------------------------------------------
>> [INFO] BUILD SUCCESS
>> [INFO] ------------------------------------------------------------------------
>> [INFO] Total time: 3.000s
>> [INFO] Finished at: Sun Dec 18 14:10:07 CST 2011
>> [INFO] Final Memory: 12M/104M
>> [INFO] ------------------------------------------------------------------------
>> C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest>java -cp target/Maven
>> Test-1.0-SNAPSHOT.jar org.JasonThomas.ShadowInnovations
>> Error: Could not find or load main class org.JasonThomas.ShadowInnovations
>>
>> C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest>
>>
>>
>>
>> ________________________________
>> From: Robert Scholte [via Maven] <[hidden email]>
>> To: Apache Omega <[hidden email]>
>> Sent: Sunday, December 18, 2011 1:21 PM
>> Subject: RE: having problems with java -cp taget command
>>
>>
>>
>>
>> This problem has nothing to do with Maven, it's java basics.
>>
>> First of all, you shouldn't look under src/main/java, this is not on the classpath. You should look in the jar.
>>
>> The real problem is a typo:
>>
>> org.JasnThomas.ShadowInnovations
>>
>> org.JasonThomas.ShadowInnovations
>>
>>
>>
>> see the difference?
>>
>>
>>
>> -Robert
>>
>>
>>
>> ps. try to keep packagenames lowercase.
>>
>>
>>
>>> Date: Sun, 18 Dec 2011 11:14:20 -0800
>>> From: [hidden email]
>>> To: [hidden email]
>>> Subject: having problems with java -cp taget command
>>>
>>> I've worked out some kinks just to find another kink
>>> i entered (java -cp target/MavenTestApp-1.0-SNAPSHOT.jar
>>> org.JasnThomas.ShadowInnovations) and the message i got was could not find
>>> or load main class org.JasonThomas.ShadowInnovations and the folder is
>>> clearly in the right path
>>> src/main/java/org/JasonThomas/ShadowInnovations/App.java
>>>
>>> how is this possible when the folder is clearly there
>>>
>>> p.s. sorry i'm posting so much I'm just trying to get started quickly -
>>> losing time on actually programing messing around with all this but i gotta
>>> learn it.
>>>
>>>
>>> --
>>> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084317.html
>>> Sent from the Maven - Users mailing list archive at Nabble.com.
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: [hidden email]
>>> For additional commands, e-mail: [hidden email]
>>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [hidden email]
>> For additional commands, e-mail: [hidden email]
>>
>>
>>
>> ________________________________
>>
>> If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084324.html
>> To unsubscribe from having problems with java -cp taget command, click here.
>> NAML
>>
>> --
>> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084424.html
>> Sent from the Maven - Users mailing list archive at Nabble.com.                         ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>
>
> ________________________________
>
> If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084433.html
> To unsubscribe from having problems with java -cp taget command, click here.
> NAML
>
> --
> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084499.html
> Sent from the Maven - Users mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: having problems with java -cp taget command

Posted by Apache Omega <ja...@yahoo.com>.
with 'o'



________________________________
 From: Robert Scholte [via Maven] <ml...@n5.nabble.com>
To: Apache Omega <ja...@yahoo.com> 
Sent: Sunday, December 18, 2011 2:21 PM
Subject: RE: having problems with java -cp taget command
 


Is Jason with or without 'o'? 
  



> Date: Sun, 18 Dec 2011 12:15:53 -0800 
> From: [hidden email] 
> To: [hidden email] 
> Subject: Re: having problems with java -cp taget command 
> 
> I tried it again and it still gives me the same error I copied the code and this is what it says 
> 
> I just don't understand this problem 
> 
> ------------------------------------------------------- 
> T E S T S 
> ------------------------------------------------------- 
> Running org.JasonThomas.ShadowInnovations.AppTest 
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.013 sec 
> 
> Results : 
> 
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0 
> 
> [INFO] 
> [INFO] --- maven-jar-plugin:2.3.1:jar (default-jar) @ MavenTest --- 
> [INFO] Building jar: C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest\ 
> target\MavenTest-1.0-SNAPSHOT.jar 
> [INFO] ------------------------------------------------------------------------ 
> [INFO] BUILD SUCCESS 
> [INFO] ------------------------------------------------------------------------ 
> [INFO] Total time: 3.000s 
> [INFO] Finished at: Sun Dec 18 14:10:07 CST 2011 
> [INFO] Final Memory: 12M/104M 
> [INFO] ------------------------------------------------------------------------ 
> C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest>java -cp target/Maven 
> Test-1.0-SNAPSHOT.jar org.JasonThomas.ShadowInnovations 
> Error: Could not find or load main class org.JasonThomas.ShadowInnovations 
> 
> C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest> 
> 
> 
> 
> ________________________________ 
> From: Robert Scholte [via Maven] <[hidden email]> 
> To: Apache Omega <[hidden email]> 
> Sent: Sunday, December 18, 2011 1:21 PM 
> Subject: RE: having problems with java -cp taget command 
> 
> 
> 
> 
> This problem has nothing to do with Maven, it's java basics. 
> 
> First of all, you shouldn't look under src/main/java, this is not on the classpath. You should look in the jar. 
> 
> The real problem is a typo: 
> 
> org.JasnThomas.ShadowInnovations 
> 
> org.JasonThomas.ShadowInnovations 
> 
> 
> 
> see the difference? 
> 
> 
> 
> -Robert 
> 
> 
> 
> ps. try to keep packagenames lowercase. 
> 
> 
> 
> > Date: Sun, 18 Dec 2011 11:14:20 -0800 
> > From: [hidden email] 
> > To: [hidden email] 
> > Subject: having problems with java -cp taget command 
> > 
> > I've worked out some kinks just to find another kink 
> > i entered (java -cp target/MavenTestApp-1.0-SNAPSHOT.jar 
> > org.JasnThomas.ShadowInnovations) and the message i got was could not find 
> > or load main class org.JasonThomas.ShadowInnovations and the folder is 
> > clearly in the right path 
> > src/main/java/org/JasonThomas/ShadowInnovations/App.java 
> > 
> > how is this possible when the folder is clearly there 
> > 
> > p.s. sorry i'm posting so much I'm just trying to get started quickly - 
> > losing time on actually programing messing around with all this but i gotta 
> > learn it. 
> > 
> > 
> > -- 
> > View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084317.html
> > Sent from the Maven - Users mailing list archive at Nabble.com. 
> > 
> > --------------------------------------------------------------------- 
> > To unsubscribe, e-mail: [hidden email] 
> > For additional commands, e-mail: [hidden email] 
> > --------------------------------------------------------------------- 
> To unsubscribe, e-mail: [hidden email] 
> For additional commands, e-mail: [hidden email] 
> 
> 
> 
> ________________________________ 
> 
> If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084324.html  
> To unsubscribe from having problems with java -cp taget command, click here. 
> NAML 
> 
> -- 
> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084424.html
> Sent from the Maven - Users mailing list archive at Nabble.com. 		 	   		   --------------------------------------------------------------------- 
To unsubscribe, e-mail: [hidden email] 
For additional commands, e-mail: [hidden email] 



________________________________
 
If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084433.html 
To unsubscribe from having problems with java -cp taget command, click here.
NAML

--
View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084499.html
Sent from the Maven - Users mailing list archive at Nabble.com.

Re: having problems with java -cp taget command

Posted by Apache Omega <ja...@yahoo.com>.

its even in my POM so why cant it find it?

- <projectxmlns="http://maven.apache.org/POM/4.0.0"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion> 
  <groupId>org.JasonThomas.ShadowInnovations</groupId>        (it's right here*********************) 
  <artifactId>MavenTest</artifactId> 
  <version>1.0-SNAPSHOT</version> 
  <packaging>jar</packaging> 
  <name>MavenTest</name> 
  <url>http://maven.apache.org</url> 
- <properties>
  <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> 
  </properties>
- <dependencies>
- <dependency>
  <groupId>junit</groupId> 
  <artifactId>junit</artifactId> 
  <version>3.8.1</version> 
  <scope>test</scope> 
  </dependency>
  </dependencies>
  </project>


________________________________
 From: Robert Scholte [via Maven] <ml...@n5.nabble.com>
To: Apache Omega <ja...@yahoo.com> 
Sent: Sunday, December 18, 2011 2:21 PM
Subject: RE: having problems with java -cp taget command
 


Is Jason with or without 'o'? 
  



> Date: Sun, 18 Dec 2011 12:15:53 -0800 
> From: [hidden email] 
> To: [hidden email] 
> Subject: Re: having problems with java -cp taget command 
> 
> I tried it again and it still gives me the same error I copied the code and this is what it says 
> 
> I just don't understand this problem 
> 
> ------------------------------------------------------- 
> T E S T S 
> ------------------------------------------------------- 
> Running org.JasonThomas.ShadowInnovations.AppTest 
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.013 sec 
> 
> Results : 
> 
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0 
> 
> [INFO] 
> [INFO] --- maven-jar-plugin:2.3.1:jar (default-jar) @ MavenTest --- 
> [INFO] Building jar: C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest\ 
> target\MavenTest-1.0-SNAPSHOT.jar 
> [INFO] ------------------------------------------------------------------------ 
> [INFO] BUILD SUCCESS 
> [INFO] ------------------------------------------------------------------------ 
> [INFO] Total time: 3.000s 
> [INFO] Finished at: Sun Dec 18 14:10:07 CST 2011 
> [INFO] Final Memory: 12M/104M 
> [INFO] ------------------------------------------------------------------------ 
> C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest>java -cp target/Maven 
> Test-1.0-SNAPSHOT.jar org.JasonThomas.ShadowInnovations 
> Error: Could not find or load main class org.JasonThomas.ShadowInnovations 
> 
> C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest> 
> 
> 
> 
> ________________________________ 
> From: Robert Scholte [via Maven] <[hidden email]> 
> To: Apache Omega <[hidden email]> 
> Sent: Sunday, December 18, 2011 1:21 PM 
> Subject: RE: having problems with java -cp taget command 
> 
> 
> 
> 
> This problem has nothing to do with Maven, it's java basics. 
> 
> First of all, you shouldn't look under src/main/java, this is not on the classpath. You should look in the jar. 
> 
> The real problem is a typo: 
> 
> org.JasnThomas.ShadowInnovations 
> 
> org.JasonThomas.ShadowInnovations 
> 
> 
> 
> see the difference? 
> 
> 
> 
> -Robert 
> 
> 
> 
> ps. try to keep packagenames lowercase. 
> 
> 
> 
> > Date: Sun, 18 Dec 2011 11:14:20 -0800 
> > From: [hidden email] 
> > To: [hidden email] 
> > Subject: having problems with java -cp taget command 
> > 
> > I've worked out some kinks just to find another kink 
> > i entered (java -cp target/MavenTestApp-1.0-SNAPSHOT.jar 
> > org.JasnThomas.ShadowInnovations) and the message i got was could not find 
> > or load main class org.JasonThomas.ShadowInnovations and the folder is 
> > clearly in the right path 
> > src/main/java/org/JasonThomas/ShadowInnovations/App.java 
> > 
> > how is this possible when the folder is clearly there 
> > 
> > p.s. sorry i'm posting so much I'm just trying to get started quickly - 
> > losing time on actually programing messing around with all this but i gotta 
> > learn it. 
> > 
> > 
> > -- 
> > View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084317.html
> > Sent from the Maven - Users mailing list archive at Nabble.com. 
> > 
> > --------------------------------------------------------------------- 
> > To unsubscribe, e-mail: [hidden email] 
> > For additional commands, e-mail: [hidden email] 
> > --------------------------------------------------------------------- 
> To unsubscribe, e-mail: [hidden email] 
> For additional commands, e-mail: [hidden email] 
> 
> 
> 
> ________________________________ 
> 
> If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084324.html  
> To unsubscribe from having problems with java -cp taget command, click here. 
> NAML 
> 
> -- 
> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084424.html
> Sent from the Maven - Users mailing list archive at Nabble.com. 		 	   		   --------------------------------------------------------------------- 
To unsubscribe, e-mail: [hidden email] 
For additional commands, e-mail: [hidden email] 



________________________________
 
If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084433.html 
To unsubscribe from having problems with java -cp taget command, click here.
NAML

--
View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084551.html
Sent from the Maven - Users mailing list archive at Nabble.com.

RE: having problems with java -cp taget command

Posted by Robert Scholte <rf...@codehaus.org>.
Is Jason with or without 'o'?
 


> Date: Sun, 18 Dec 2011 12:15:53 -0800
> From: jason007thomas@yahoo.com
> To: users@maven.apache.org
> Subject: Re: having problems with java -cp taget command
> 
> I tried it again and it still gives me the same error I copied the code and this is what it says
> 
> I just don't understand this problem
> 
> -------------------------------------------------------
> T E S T S
> -------------------------------------------------------
> Running org.JasonThomas.ShadowInnovations.AppTest
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.013 sec
> 
> Results :
> 
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0
> 
> [INFO]
> [INFO] --- maven-jar-plugin:2.3.1:jar (default-jar) @ MavenTest ---
> [INFO] Building jar: C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest\
> target\MavenTest-1.0-SNAPSHOT.jar
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 3.000s
> [INFO] Finished at: Sun Dec 18 14:10:07 CST 2011
> [INFO] Final Memory: 12M/104M
> [INFO] ------------------------------------------------------------------------
> C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest>java -cp target/Maven
> Test-1.0-SNAPSHOT.jar org.JasonThomas.ShadowInnovations
> Error: Could not find or load main class org.JasonThomas.ShadowInnovations
> 
> C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest>
> 
> 
> 
> ________________________________
> From: Robert Scholte [via Maven] <ml...@n5.nabble.com>
> To: Apache Omega <ja...@yahoo.com> 
> Sent: Sunday, December 18, 2011 1:21 PM
> Subject: RE: having problems with java -cp taget command
> 
> 
> 
> 
> This problem has nothing to do with Maven, it's java basics. 
> 
> First of all, you shouldn't look under src/main/java, this is not on the classpath. You should look in the jar. 
> 
> The real problem is a typo: 
> 
> org.JasnThomas.ShadowInnovations 
> 
> org.JasonThomas.ShadowInnovations 
> 
> 
> 
> see the difference? 
> 
> 
> 
> -Robert 
> 
> 
> 
> ps. try to keep packagenames lowercase. 
> 
> 
> 
> > Date: Sun, 18 Dec 2011 11:14:20 -0800 
> > From: [hidden email] 
> > To: [hidden email] 
> > Subject: having problems with java -cp taget command 
> > 
> > I've worked out some kinks just to find another kink 
> > i entered (java -cp target/MavenTestApp-1.0-SNAPSHOT.jar 
> > org.JasnThomas.ShadowInnovations) and the message i got was could not find 
> > or load main class org.JasonThomas.ShadowInnovations and the folder is 
> > clearly in the right path 
> > src/main/java/org/JasonThomas/ShadowInnovations/App.java 
> > 
> > how is this possible when the folder is clearly there 
> > 
> > p.s. sorry i'm posting so much I'm just trying to get started quickly - 
> > losing time on actually programing messing around with all this but i gotta 
> > learn it. 
> > 
> > 
> > -- 
> > View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084317.html
> > Sent from the Maven - Users mailing list archive at Nabble.com. 
> > 
> > --------------------------------------------------------------------- 
> > To unsubscribe, e-mail: [hidden email] 
> > For additional commands, e-mail: [hidden email] 
> > --------------------------------------------------------------------- 
> To unsubscribe, e-mail: [hidden email] 
> For additional commands, e-mail: [hidden email] 
> 
> 
> 
> ________________________________
> 
> If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084324.html 
> To unsubscribe from having problems with java -cp taget command, click here.
> NAML
> 
> --
> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084424.html
> Sent from the Maven - Users mailing list archive at Nabble.com. 		 	   		  
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: having problems with java -cp taget command

Posted by Apache Omega <ja...@yahoo.com>.
I tried it again and it still gives me the same error I copied the code and this is what it says

I just don't understand this problem

-------------------------------------------------------
 T E S T S
-------------------------------------------------------
Running org.JasonThomas.ShadowInnovations.AppTest
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.013 sec

Results :

Tests run: 1, Failures: 0, Errors: 0, Skipped: 0

[INFO]
[INFO] --- maven-jar-plugin:2.3.1:jar (default-jar) @ MavenTest ---
[INFO] Building jar: C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest\
target\MavenTest-1.0-SNAPSHOT.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.000s
[INFO] Finished at: Sun Dec 18 14:10:07 CST 2011
[INFO] Final Memory: 12M/104M
[INFO] ------------------------------------------------------------------------
C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest>java -cp target/Maven
Test-1.0-SNAPSHOT.jar org.JasonThomas.ShadowInnovations
Error: Could not find or load main class org.JasonThomas.ShadowInnovations

C:\Program Files\apache-maven-3.0.3\my-app\joker\MavenTest>



________________________________
 From: Robert Scholte [via Maven] <ml...@n5.nabble.com>
To: Apache Omega <ja...@yahoo.com> 
Sent: Sunday, December 18, 2011 1:21 PM
Subject: RE: having problems with java -cp taget command
 



This problem has nothing to do with Maven, it's java basics. 

First of all, you shouldn't look under src/main/java, this is not on the classpath. You should look in the jar. 

The real problem is a typo: 

org.JasnThomas.ShadowInnovations 

org.JasonThomas.ShadowInnovations 

  

see the difference? 

  

-Robert 

  

ps. try to keep packagenames lowercase. 



> Date: Sun, 18 Dec 2011 11:14:20 -0800 
> From: [hidden email] 
> To: [hidden email] 
> Subject: having problems with java -cp taget command 
> 
> I've worked out some kinks just to find another kink 
> i entered (java -cp target/MavenTestApp-1.0-SNAPSHOT.jar 
> org.JasnThomas.ShadowInnovations) and the message i got was could not find 
> or load main class org.JasonThomas.ShadowInnovations and the folder is 
> clearly in the right path 
> src/main/java/org/JasonThomas/ShadowInnovations/App.java 
> 
> how is this possible when the folder is clearly there 
> 
> p.s. sorry i'm posting so much I'm just trying to get started quickly - 
> losing time on actually programing messing around with all this but i gotta 
> learn it. 
> 
> 
> -- 
> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084317.html
> Sent from the Maven - Users mailing list archive at Nabble.com. 
> 
> --------------------------------------------------------------------- 
> To unsubscribe, e-mail: [hidden email] 
> For additional commands, e-mail: [hidden email] 
>  		 	   		   --------------------------------------------------------------------- 
To unsubscribe, e-mail: [hidden email] 
For additional commands, e-mail: [hidden email] 



________________________________
 
If you reply to this email, your message will be added to the discussion below:http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084324.html 
To unsubscribe from having problems with java -cp taget command, click here.
NAML

--
View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084424.html
Sent from the Maven - Users mailing list archive at Nabble.com.

RE: having problems with java -cp taget command

Posted by Robert Scholte <rf...@codehaus.org>.

This problem has nothing to do with Maven, it's java basics.

First of all, you shouldn't look under src/main/java, this is not on the classpath. You should look in the jar.

The real problem is a typo: 

org.JasnThomas.ShadowInnovations

org.JasonThomas.ShadowInnovations

 

see the difference?

 

-Robert

 

ps. try to keep packagenames lowercase.


> Date: Sun, 18 Dec 2011 11:14:20 -0800
> From: jason007thomas@yahoo.com
> To: users@maven.apache.org
> Subject: having problems with java -cp taget command
> 
> I've worked out some kinks just to find another kink
> i entered (java -cp target/MavenTestApp-1.0-SNAPSHOT.jar
> org.JasnThomas.ShadowInnovations) and the message i got was could not find
> or load main class org.JasonThomas.ShadowInnovations and the folder is
> clearly in the right path
> src/main/java/org/JasonThomas/ShadowInnovations/App.java
> 
> how is this possible when the folder is clearly there
> 
> p.s. sorry i'm posting so much I'm just trying to get started quickly -
> losing time on actually programing messing around with all this but i gotta
> learn it.
> 
> 
> --
> View this message in context: http://maven.40175.n5.nabble.com/having-problems-with-java-cp-taget-command-tp5084317p5084317.html
> Sent from the Maven - Users mailing list archive at Nabble.com.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>  		 	   		  
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org