Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

no main manifest attribute, in target/cassandra-migration-1.0.jar #16

Open
adamkleingit opened this issue Feb 24, 2016 · 1 comment
Open

Comments

@adamkleingit
Copy link

Hi,
We’re working with Cassandra in a project,
And I’m trying to use cassandra-migration library for migrations using CQL files.

I couldn’t understand how I run the migrations from command line.

I created a pom.xml with dependency to cassandra-migration.
And a db/migrations folder with one CQL file.
Then I run mvn install
And java -jar \ -Dcassandra.migration.keyspace.name=audit \ target/cassandra-migration-1.0.jar migrate

But I get:
no main manifest attribute, in target/cassandra-migration-1.0.jar

Is there someone who can help me get it running?

Thanks a lot!

@adamkleingit
Copy link
Author

That's my pom.xml file (then I just run mvn install):

<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 http://www.w3.org/2001/XMLSchema-instance ">
  <modelVersion>4.0.0</modelVersion>
  <groupId>com.lifion</groupId>
  <version>1.0</version>
  <artifactId>cassandra-migration</artifactId>
  <name>Cassandra Migration</name>
  <dependencies>
    <dependency>
      <groupId>com.contrastsecurity</groupId>
      <artifactId>cassandra-migration</artifactId>
      <version>0.6</version>
    </dependency>
  </dependencies>
  <build>
    <plugins>
      <plugin>
        <!-- Build an executable JAR -->
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jar-plugin</artifactId>
        <version>2.4</version>
        <configuration>
          <archive>
            <manifest>
              <addClasspath>true</addClasspath>
              <classpathPrefix>lib/</classpathPrefix>
              <mainClass>com.contrastsecurity.cassandra.migration.CassandraMigration</mainClass>
            </manifest>
          </archive>
        </configuration>
      </plugin>
    </plugins>
  </build>
</project>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant