From e5568f55a6a149adfd19ad04b264a69078288f86 Mon Sep 17 00:00:00 2001 From: Albert Magyar Date: Mon, 20 Jul 2020 12:17:49 -0700 Subject: Remove scalastyle configs from repository * Drop plugin * Drop scalastyle tests from make recipes * Remove checkstyle from CI --- .circleci/config.yml | 21 +-------- .mergify.yml | 3 -- Makefile | 7 +-- build.sbt | 1 - project/plugins.sbt | 2 - scalastyle-config.xml | 110 --------------------------------------------- scalastyle-test-config.xml | 109 -------------------------------------------- 7 files changed, 3 insertions(+), 250 deletions(-) delete mode 100644 scalastyle-config.xml delete mode 100644 scalastyle-test-config.xml diff --git a/.circleci/config.yml b/.circleci/config.yml index 78ae63b2..3fac3c38 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -25,7 +25,6 @@ executors: TREADLE_REPO: git@github.com:freechipsproject/treadle.git TREADLE_BRANCH: master TREADLE_REV: master - CHECKSTYLE_LIMIT: 40 SBT_ARGS: "" commands: @@ -152,17 +151,6 @@ jobs: - test-chisel: scalaVersion: "++2.12.11" - checkstyle-chisel: - executor: chisel-executor - steps: - - attach_workspace: - at: /home/chisel - - - run: - command: | - # We expect the "[info]" field from sbt so the warning count will be in column 4 - (cd chisel3 && cat /dev/null | sbt $SBT_ARGS scalastyle | gawk -v WARN_FAIL=2 -e '/scalastyle Found [0-9]+ warnings/ { print $0; if ($4 > ENVIRON["CHECKSTYLE_LIMIT"]) WARN_FAIL=1; else if (WARN_FAIL == 2) WARN_FAIL=0 }' -e 'END { exit WARN_FAIL}') - workflows: build_and_test: @@ -180,11 +168,4 @@ workflows: - test-chisel-2_12: requires: - build-treadle - - checkstyle-chisel: - # Strictly speaking, this is only dependent on build-firrtl, - # but it is faster than the test jobs so if it fails, - # it fails the entire build before we get a chance to complete the tests. - # If we make it dependent on at least one of the tests, - # there's a better chance to see if the tests fail before we flag a style failure - requires: - - test-chisel-2_12 + diff --git a/.mergify.yml b/.mergify.yml index 1698ab94..c4310021 100644 --- a/.mergify.yml +++ b/.mergify.yml @@ -10,7 +10,6 @@ pull_request_rules: conditions: - "status-success=ci/circleci: build-firrtl" - "status-success=ci/circleci: build-prep" - - "status-success=ci/circleci: checkstyle-chisel" - "status-success=ci/circleci: test-chisel-2_11" - "status-success=ci/circleci: test-chisel-2_12" - status-success=license/cla @@ -66,7 +65,6 @@ pull_request_rules: conditions: - "status-success=ci/circleci: build-firrtl" - "status-success=ci/circleci: build-prep" - - "status-success=ci/circleci: checkstyle-chisel" - "status-success=ci/circleci: test-chisel-2_11" - "status-success=ci/circleci: test-chisel-2_12" - "status-success=ci/circleci: check-binary-compatibility" @@ -86,7 +84,6 @@ pull_request_rules: conditions: - "status-success=ci/circleci: build-firrtl" - "status-success=ci/circleci: build-prep" - - "status-success=ci/circleci: checkstyle-chisel" - "status-success=ci/circleci: test-chisel-2_11" - "status-success=ci/circleci: test-chisel-2_12" - "status-success=ci/circleci: check-binary-compatibility" diff --git a/Makefile b/Makefile index 9184c09c..fdafb791 100644 --- a/Makefile +++ b/Makefile @@ -28,7 +28,7 @@ CHISEL_VERSION = $(shell "$(SBT)" $(SBT_FLAGS) "show version" | tail -n 1 | cut TEST_OUTPUT_DIR ?= ./test_run_dur RM_DIRS := $(TEST_OUTPUT_DIR) -.PHONY: smoke publish-local pubishLocal check clean jenkins-build coverage scaladoc test checkstyle compile \ +.PHONY: smoke publish-local pubishLocal check clean jenkins-build coverage scaladoc test compile \ mill.build mill.test mill.publishLocal mill.build.all mill.test.all mill.publishLocal.all mill-tools default: publishLocal @@ -42,9 +42,6 @@ publish-local publishLocal: test: $(SBT) $(SBT_FLAGS) test -checkstyle: - $(SBT) $(SBT_FLAGS) scalastyle test:scalastyle - coverage: $(SBT) $(SBT_FLAGS) coverage test $(SBT) $(SBT_FLAGS) coverageReport coverageAggregate @@ -72,7 +69,7 @@ site: jenkins-build: clean $(SBT) $(SBT_FLAGS) test $(SBT) $(SBT_FLAGS) clean publishLocal - $(SBT) $(SBT_FLAGS) scalastyle coverage test + $(SBT) $(SBT_FLAGS) coverage test $(SBT) $(SBT_FLAGS) coverageReport # Compile and package jar diff --git a/build.sbt b/build.sbt index ab280be8..ea0c0a15 100644 --- a/build.sbt +++ b/build.sbt @@ -46,7 +46,6 @@ lazy val commonSettings = Seq ( scalacOptions := Seq("-deprecation", "-feature") ++ scalacOptionsVersion(scalaVersion.value), libraryDependencies += "org.scala-lang" % "scala-reflect" % scalaVersion.value, addCompilerPlugin("org.scalamacros" % "paradise" % "2.1.1" cross CrossVersion.full), - (scalastyleConfig in Test) := (baseDirectory in root).value / "scalastyle-test-config.xml", // Use the root project's unmanaged base for all sub-projects. unmanagedBase := (unmanagedBase in root).value, // Since we want to examine the classpath to determine if a dependency on firrtl is required, diff --git a/project/plugins.sbt b/project/plugins.sbt index 48f031e2..48c2fba3 100644 --- a/project/plugins.sbt +++ b/project/plugins.sbt @@ -4,8 +4,6 @@ resolvers += Classpaths.sbtPluginReleases resolvers += "jgit-repo" at "https://download.eclipse.org/jgit/maven" -addSbtPlugin("org.scalastyle" %% "scalastyle-sbt-plugin" % "1.0.0") - addSbtPlugin("org.scoverage" % "sbt-scoverage" % "1.6.1") addSbtPlugin("com.typesafe.sbt" % "sbt-site" % "1.4.0") diff --git a/scalastyle-config.xml b/scalastyle-config.xml deleted file mode 100644 index 67aa8afe..00000000 --- a/scalastyle-config.xml +++ /dev/null @@ -1,110 +0,0 @@ - - Scalastyle standard configuration - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - No lines ending with a ; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |\|\||&&|:=|<>|<=|>=|!=|===|=/=|<<|>>|##|unary_(~|\-%?|!))$]]> - - - - - - - - - - - diff --git a/scalastyle-test-config.xml b/scalastyle-test-config.xml deleted file mode 100644 index 50953819..00000000 --- a/scalastyle-test-config.xml +++ /dev/null @@ -1,109 +0,0 @@ - - Scalastyle configuration for Chisel3 unit tests - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - No lines ending with a ; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |\|\||&&|:=|<>|<=|>=|!=|===|=/=|<<|>>|##|unary_(~|\-%?|!))$]]> - - - - - - - - - - - -- cgit v1.2.3