This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

View | Details | Raw Unified | Return to bug 251077
Collapse All | Expand All

(-)src/main/java/org/codehaus/mojo/nbm/repository/PopulateRepositoryMojo.java (-5 / +14 lines)
Lines 352-366 Link Here
352
            if ( examinator.isNetBeansModule() || examinator.isOsgiBundle() )
352
            if ( examinator.isNetBeansModule() || examinator.isOsgiBundle() )
353
            {
353
            {
354
                //TODO get artifact id from the module's manifest?
354
                //TODO get artifact id from the module's manifest?
355
                String artifact = module.getName().substring( 0, module.getName().indexOf( ".jar" ) );
355
                String fileArtifact = module.getName().substring( 0, module.getName().indexOf( ".jar" ) );
356
                if ( "boot".equals( artifact ) )
356
                if ( "boot".equals( fileArtifact ) )
357
                {
357
                {
358
                    artifact = "org-netbeans-bootstrap";
358
                    fileArtifact = "org-netbeans-bootstrap";
359
                }
359
                }
360
                if ( "core".equals( artifact ) )
360
                if ( "core".equals( fileArtifact ) )
361
                {
361
                {
362
                    artifact = "org-netbeans-core-startup";
362
                    fileArtifact = "org-netbeans-core-startup";
363
                }
363
                }
364
                String artifact = examinator.getModule();
365
                if (artifact == null) {
366
                    artifact = fileArtifact;
367
                } else {
368
                    artifact = artifact.replaceAll("\\.", "-");
369
                }
370
//                if (!fileArtifact.equals(artifact)) {
371
//                    System.err.println("WARNING: file-based artifact name differs from module name: " + fileArtifact + ":"  + artifact);
372
//                }
364
                String version = forcedVersion == null ? examinator.getSpecVersion() : forcedVersion;
373
                String version = forcedVersion == null ? examinator.getSpecVersion() : forcedVersion;
365
                String group = examinator.isOsgiBundle() ? GROUP_EXTERNAL : examinator.hasPublicPackages() ? GROUP_API : GROUP_IMPL;
374
                String group = examinator.isOsgiBundle() ? GROUP_EXTERNAL : examinator.hasPublicPackages() ? GROUP_API : GROUP_IMPL;
366
                Artifact art = createArtifact( artifact, version, group );
375
                Artifact art = createArtifact( artifact, version, group );

Return to bug 251077