First OpenMRS module

Hello,

Under the step of creating my first OpenMRS module with codes in command prompt (mvn openmrs-sdk:clone -DgroupId=org.openmrs.module -DartifactId=webservices.rest), It displays build failure and states error: failed to execute goal org.openmrs.maven.plugins:openmrs-sdk-maven-plugin:3.13.2:watch (default-cli) on project standalone-pom: command must be run from openmrs -core or modules main directory.

I have tried for several times but failed.

Please, advise on how best to solve this.

Can you share a screenshot of what you see on your command prompt?

I can see the error message in red saying that the folder already exists, meaning that the clone was successful. Can you cross check to confirm that it really exists? You can proceed to the next command.

Yes, that one is okay but

The problem is with the highlighted run.

Please, check it out. Its error message shows failed to execute…

Hey @mmark, change your directory to “C:\Users\hp\openmrs-module-webservices.rest” and run watch command

Thank you very much but in cmd, its texting not recognised as an internal or external command

which command you run?

mvn openmrs-sdk:watch -DserverId=webservices-dev

Error: failed to execute goal…standalone-pom: command must be run from the openmrs-core or module’s main directory

What can i do next from the above?

Can you share the entire screen? Just like the one you shared above.

Run this command:

cd openmrs-module-webservices.rest

Then run your command again:

mvn openmrs-sdk:watch -DserverId=webservices-dev

1 Like

Thank you very much.

See print screen, still not okay

Can you include the part of your screen where you typed the command?

What does this command return? dir

Hello,

Please, see return for dir command

Run the dir command from the same folder in which you were running the sdk watch command.

Do you mean this below?