From 152cf9835b1cfd4a817b83ec48e2b1f474e8490f Mon Sep 17 00:00:00 2001 From: Simon Brandhof Date: Tue, 18 Mar 2014 15:22:28 +0100 Subject: [PATCH] SONAR-5143 revert. Inclusions are coming back to UI ! Conflicts: sonar-core/src/main/java/org/sonar/core/persistence/DatabaseVersion.java sonar-core/src/main/resources/org/sonar/core/persistence/rows-h2.sql sonar-server/src/main/webapp/WEB-INF/db/migrate/499_delete_inclusions_properties.rb --- .../plugins/core/ExclusionProperties.java | 10 +++--- .../org/sonar/core/persistence/rows-h2.sql | 1 - .../499_delete_inclusions_properties.rb | 35 ------------------- 3 files changed, 4 insertions(+), 42 deletions(-) delete mode 100644 sonar-server/src/main/webapp/WEB-INF/db/migrate/499_delete_inclusions_properties.rb diff --git a/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/ExclusionProperties.java b/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/ExclusionProperties.java index 00d7e7c0611..b169a572965 100644 --- a/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/ExclusionProperties.java +++ b/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/ExclusionProperties.java @@ -34,24 +34,22 @@ class ExclusionProperties { static List definitions() { return ImmutableList.of( - - // Do not display inclusions in UI - // https://jira.codehaus.org/browse/SONAR-5143 PropertyDefinition.builder(CoreProperties.PROJECT_INCLUSIONS_PROPERTY) .name("Source File Inclusions") .multiValues(true) .category(CoreProperties.CATEGORY_EXCLUSIONS) .subCategory(CoreProperties.SUBCATEGORY_FILES_EXCLUSIONS) - .hidden() + .onQualifiers(Qualifiers.PROJECT) + .index(3) .build(), PropertyDefinition.builder(CoreProperties.PROJECT_TEST_INCLUSIONS_PROPERTY) .name("Test File Inclusions") .multiValues(true) .category(CoreProperties.CATEGORY_EXCLUSIONS) .subCategory(CoreProperties.SUBCATEGORY_FILES_EXCLUSIONS) - .hidden() + .onQualifiers(Qualifiers.PROJECT) + .index(5) .build(), - PropertyDefinition.builder(CoreProperties.GLOBAL_EXCLUSIONS_PROPERTY) .name("Global Source File Exclusions") .multiValues(true) diff --git a/sonar-core/src/main/resources/org/sonar/core/persistence/rows-h2.sql b/sonar-core/src/main/resources/org/sonar/core/persistence/rows-h2.sql index d01a3101ee4..b924803a886 100644 --- a/sonar-core/src/main/resources/org/sonar/core/persistence/rows-h2.sql +++ b/sonar-core/src/main/resources/org/sonar/core/persistence/rows-h2.sql @@ -208,7 +208,6 @@ INSERT INTO SCHEMA_MIGRATIONS(VERSION) VALUES ('495'); INSERT INTO SCHEMA_MIGRATIONS(VERSION) VALUES ('496'); INSERT INTO SCHEMA_MIGRATIONS(VERSION) VALUES ('497'); INSERT INTO SCHEMA_MIGRATIONS(VERSION) VALUES ('498'); -INSERT INTO SCHEMA_MIGRATIONS(VERSION) VALUES ('499'); INSERT INTO SCHEMA_MIGRATIONS(VERSION) VALUES ('510'); INSERT INTO SCHEMA_MIGRATIONS(VERSION) VALUES ('511'); INSERT INTO SCHEMA_MIGRATIONS(VERSION) VALUES ('512'); diff --git a/sonar-server/src/main/webapp/WEB-INF/db/migrate/499_delete_inclusions_properties.rb b/sonar-server/src/main/webapp/WEB-INF/db/migrate/499_delete_inclusions_properties.rb deleted file mode 100644 index 84a8bfb9899..00000000000 --- a/sonar-server/src/main/webapp/WEB-INF/db/migrate/499_delete_inclusions_properties.rb +++ /dev/null @@ -1,35 +0,0 @@ -# -# SonarQube, open source software quality management tool. -# Copyright (C) 2008-2013 SonarSource -# mailto:contact AT sonarsource DOT com -# -# SonarQube is free software; you can redistribute it and/or -# modify it under the terms of the GNU Lesser General Public -# License as published by the Free Software Foundation; either -# version 3 of the License, or (at your option) any later version. -# -# SonarQube is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# Lesser General Public License for more details. -# -# You should have received a copy of the GNU Lesser General Public License -# along with this program; if not, write to the Free Software Foundation, -# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -# - -# -# SonarQube 4.2 -# SONAR-5143 -# -class DeleteInclusionsProperties < ActiveRecord::Migration - - class Property < ActiveRecord::Base - end - - def self.up - Property.delete_all("prop_key = 'sonar.inclusions'") - Property.delete_all("prop_key = 'sonar.test.inclusions'") - end - -end -- 2.39.5