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.

Bug 251110 - rename platform app project&directory; this disassociates suite-components
Summary: rename platform app project&directory; this disassociates suite-components
Status: RESOLVED FIXED
Alias: None
Product: apisupport
Classification: Unclassified
Component: Refactoring (show other bugs)
Version: 8.0.2
Hardware: PC Windows 7
: P2 normal (vote)
Assignee: Ondrej Vrabec
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-03-11 18:20 UTC by err
Modified: 2015-07-18 01:47 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description err 2015-03-11 18:20:17 UTC
- Select platform app
  note: It has a few modules in sibling directories.
        It has a couple of wrapped libraries, guava and checker-qual, sub-dirs
- rename platform app
observe: Error annouce: C:\a\src\wb-dev\wb\new.name\guava
         suite-component(s) converted to standalone



Here is a typical platform-app's module's directory, a sibling of platform-app dir
    $ pwd
    /a/src/wb-dev/wb/MetaWB/nbproject
    $ ls
    build-impl.xml*       private/             project.xml*
    genfiles.properties*  project.properties*  suite.properties*

after the rename it seems to have "divorce" the module from the app

    $ ls
    build-impl.xml*       platform.properties*  project.properties*
    genfiles.properties*  private/              project.xml*

It has removed suite.properties and added project.properties. Below is a full
"hg diff" of nbproject. Notice that <suite-component/> becomes <standalone/>


$ hg diff .
diff --git a/MetaWB/nbproject/build-impl.xml b/MetaWB/nbproject/build-impl.xml
--- a/MetaWB/nbproject/build-impl.xml
+++ b/MetaWB/nbproject/build-impl.xml
@@ -11,11 +11,8 @@
             </not>
         </condition>
     </fail>
-    <property file="nbproject/private/suite-private.properties"/>
-    <property file="nbproject/suite.properties"/>
-    <fail unless="suite.dir">You must set 'suite.dir' to point to your containing module suite</fail>
-    <property file="${suite.dir}/nbproject/private/platform-private.properties"/>
-    <property file="${suite.dir}/nbproject/platform.properties"/>
+    <property file="nbproject/private/platform-private.properties"/>
+    <property file="nbproject/platform.properties"/>
     <macrodef name="property" uri="http://www.netbeans.org/ns/nb-module-project/2">
         <attribute name="name"/>
         <attribute name="value"/>
diff --git a/MetaWB/nbproject/genfiles.properties b/MetaWB/nbproject/genfiles.properties
--- a/MetaWB/nbproject/genfiles.properties
+++ b/MetaWB/nbproject/genfiles.properties
@@ -1,8 +1,8 @@
-build.xml.data.CRC32=8e8a170d
+build.xml.data.CRC32=b1aba103
 build.xml.script.CRC32=77b32b4e
 build.xml.stylesheet.CRC32=a56c6a5b@2.67.1
 # This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
 # Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
-nbproject/build-impl.xml.data.CRC32=8e8a170d
-nbproject/build-impl.xml.script.CRC32=5d344638
+nbproject/build-impl.xml.data.CRC32=b1aba103
+nbproject/build-impl.xml.script.CRC32=82f2a5fa
 nbproject/build-impl.xml.stylesheet.CRC32=238281d1@2.67.1
diff --git a/MetaphysicalWorkbench/nbproject/platform.properties b/MetaWB/nbproject/platform.properties
copy from MetaphysicalWorkbench/nbproject/platform.properties
copy to MetaWB/nbproject/platform.properties
diff --git a/MetaWB/nbproject/project.xml b/MetaWB/nbproject/project.xml
--- a/MetaWB/nbproject/project.xml
+++ b/MetaWB/nbproject/project.xml
@@ -4,7 +4,7 @@
     <configuration>
         <data xmlns="http://www.netbeans.org/ns/nb-module-project/3">
             <code-name-base>org.metawb</code-name-base>
-            <suite-component/>
+            <standalone/>
             <module-dependencies>
                 <dependency>
                     <code-name-base>com.google.common</code-name-base>
diff --git a/MetaWB/nbproject/suite.properties b/MetaWB/nbproject/suite.properties
deleted file mode 100644
--- a/MetaWB/nbproject/suite.properties
+++ /dev/null
@@ -1,1 +0,0 @@
-suite.dir=${basedir}/../MetaphysicalWorkbench
Comment 1 Ondrej Vrabec 2015-07-16 15:10:12 UTC
Fix: http://hg.netbeans.org/core-main/rev/10f333699a4d
Comment 2 Ondrej Vrabec 2015-07-16 15:13:05 UTC
i slightly modified the rename process, now no suite.properties should be lost and no platform.properties created. It used to happen that during a rename a module was at first removed and then added to the new suite. However when removing the module it was turned into a standalone project, suite.props was lost and platform.props was created.
Comment 3 Quality Engineering 2015-07-18 01:47:27 UTC
Integrated into 'main-silver', will be available in build *201507180001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/10f333699a4d
User: Ondrej Vrabec <ovrabec@netbeans.org>
Log: #251110 - rename platform app project&directory; this disassociates suite-components
When moving/renaming do not disconnect the project at all.
Instead just rename/move the files and handle all project metadata in after-processing.