Skip to content

[BUG] packageName ignored by maven plugin #2428

@Zomzog

Description

@Zomzog

Bug Report Checklist

  • Have you provided a full/minimal spec to reproduce the issue?
  • Have you validated the input using an OpenAPI validator (example)?
  • What's the version of OpenAPI Generator used?
  • Have you search for related issues/PRs?
  • What's the actual output vs expected output?
  • [Optional] Bounty to sponsor the fix (example)
Description

packageName not used by maven plugin, infrastructure is genereted in default package.

openapi-generator version

3.2.2 and 4.0.0-SNAPSHOT

OpenAPI declaration file content or url

Maven config

<groupId>org.openapitools</groupId>
<artifactId>openapi-generator-maven-plugin</artifactId>
<executions>
    <execution>
        <goals>
            <goal>generate</goal>
        </goals>
        <configuration>
            <inputSpec>${project.basedir}/src/main/resources/swagger.json</inputSpec>
            <generatorName>kotlin</generatorName>
            <configOptions>
                <sourceFolder>src/gen/kotlin/main</sourceFolder>
            </configOptions>
            <packageName>bzh.zomzog.utils</packageName>
            <generateSupportingFiles>true</generateSupportingFiles>
        </configuration>
    </execution>
</executions>
Command line used for generation

mvn clean install

Steps to reproduce

Generate a kotlin client with custom packageName

Related issues/PRs
Suggest a fix

Add support of packageName to maven plugin

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions