Run TestNG script through terminal to start Appium session and Perform testing

I am using Appium, WebdriverAgent, TestNG to run the automation script on iPad application.When I run the .xml script from from eclipse as run as TestNG then it runs successfully and starts the session on Appium. I am trying to run the automation script through the TestNG using the terminal, but when i search for the solution i found solutions for java project like set classpath for bin and lib. I am using maven project there is no bin folder in my folder structure. I Created the lib folder which contains all the library files and created bin folder which contains the jar files which was created after maven install. what should I do, how I should run the .xml script as TestNG from terminal.