From c77092bb9a5948123d441a56b75d52ffb717b5f0 Mon Sep 17 00:00:00 2001 From: Leo Zhang Date: Fri, 2 Mar 2018 19:20:31 -0800 Subject: [PATCH] fix(mvn): Run Maven in batch mode to turn off ANSI color chars --- .circleci/config.yml | 3 +++ .fossa.yaml | 42 ++++++++---------------------------------- .gitmodules | 2 +- CHANGELOG | 23 +++++++++++++++++++++++ builders/maven.go | 2 +- test/fixtures/maven | 2 +- test/fixtures/sbt | 2 +- 7 files changed, 38 insertions(+), 38 deletions(-) create mode 100644 CHANGELOG diff --git a/.circleci/config.yml b/.circleci/config.yml index 5809be3ca4..e9171fb6f7 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -32,6 +32,9 @@ jobs: - run: name: Run integration test command: | + # Load shell helpers (e.g. sdkman) + source /home/fossa/.bashrc + # Run tests go test ./builders - run: name: Run FOSSA build diff --git a/.fossa.yaml b/.fossa.yaml index 7a84963032..e650faba62 100644 --- a/.fossa.yaml +++ b/.fossa.yaml @@ -1,38 +1,12 @@ +# Generated by FOSSA CLI (https://github.com/fossas/fossa-cli) +# Visit https://fossa.io to learn more version: 1 - cli: - # # Defaults to https://app.fossa.io - # server: https://fossa.on-prem - # api_key: some-key-here - # # If you're uploading to an existing git project, or a custom project in FOSSA - # fetcher: custom - # # If `project` is unset infer from VCS. - # project: fossa-proj - + server: https://app.fossa.io + project: git@github.com:fossas/fossa-cli.git + fetcher: git analyze: - # ignores: - # - path: github.com/kubernetes/kubernetes - # type: dependency - # - path: ./vendor/gopkg.in/yaml.v2 - # type: folder modules: - - name: fossa-cli - path: ./cmd/fossa - type: gopackage - # - name: vendored-jquery - # path: vendor/jquery-stuff/bower.json - # type: bowerpackage - -# These take a lot of inspiration from CircleCI -# build: -# working_directory: /fossa -# docker: -# - image: some-image-host/image-name -# auth: -# username: foo -# password: $BAR -# environment: -# key: value -# steps: | -# echo "test" -# ls + - name: fossa-cli + path: ./cmd/fossa + type: gopackage diff --git a/.gitmodules b/.gitmodules index 28a9a133c5..b262d3cc96 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,6 +1,6 @@ [submodule "test/fixtures/maven"] path = test/fixtures/maven - url = https://github.com/neo4j/neo4j + url = https://github.com/apache/hadoop [submodule "test/fixtures/sbt"] path = test/fixtures/sbt url = https://github.com/apache/spark diff --git a/CHANGELOG b/CHANGELOG new file mode 100644 index 0000000000..98d542904a --- /dev/null +++ b/CHANGELOG @@ -0,0 +1,23 @@ +# Changelog + +## Versioning policy + +This versioning policy only applies for versions below 1.0.0. We will develop a separate versioning policy after the 1.0.0 release. + +We generally follow semantic versioning, but semantic versioning does not specify pre-1.0.0 behavior. Here is how `fossa` pre-1.0.0 releases will work: + +- Any update that creates a breaking change (i.e. a change that causes a previously working configuration to fail) will bump the minor version. +- All other updates will bump the patch version. +- Preview, beta, and other special releases will have a pre-release identifer in the semantic version, and will be marked as pre-release on GitHub Releases. + +## Version history + +Major breaking changes and new features will be recorded here. For a much more detailed automated changelog, see the changelogs accompanying each GitHub Release. + +### 0.4.1 + +#### New features +- Managed Builds are now supported: you no longer need to have a corresponding Git project within FOSSA to upload build results. + +#### Breaking changes +- By default, new projects will use Managed Builds (i.e. their fetcher will be `custom`). This is different from the original default, which set the fetcher to be `git`. This will break your configuration if you do not explicitly set the project's fetcher. diff --git a/builders/maven.go b/builders/maven.go index 29300b40cb..82b1b0d848 100644 --- a/builders/maven.go +++ b/builders/maven.go @@ -135,7 +135,7 @@ func (builder *MavenBuilder) Analyze(m module.Module, allowUnresolved bool) ([]m func (builder *MavenBuilder) IsBuilt(m module.Module, allowUnresolved bool) (bool, error) { mavenLogger.Debugf("Checking Maven build: %#v %#v", m, allowUnresolved) - output, _, err := runLogged(mavenLogger, m.Dir, builder.MvnCmd, "dependency:list") + output, _, err := runLogged(mavenLogger, m.Dir, builder.MvnCmd, "dependency:list", "-B") if err != nil { if strings.Index(output, "Could not find artifact") != -1 { return false, nil diff --git a/test/fixtures/maven b/test/fixtures/maven index 4fe03c55ac..ac0538aac3 160000 --- a/test/fixtures/maven +++ b/test/fixtures/maven @@ -1 +1 @@ -Subproject commit 4fe03c55acce5f3e1ba8ffefddaafa340a760b2e +Subproject commit ac0538aac347bfd97cc0dee1db49db503c15f1d9 diff --git a/test/fixtures/sbt b/test/fixtures/sbt index cdcccd7b41..3a4d15e5d2 160000 --- a/test/fixtures/sbt +++ b/test/fixtures/sbt @@ -1 +1 @@ -Subproject commit cdcccd7b41c43d79edff2fec7a84cd00e9524f75 +Subproject commit 3a4d15e5d2b9ddbaeb2a6ab2d86d059ada6407b2