Skip to content

armgit / spree

Public Imported from GitHub
0

Open Source Platform for DTC, B2B Commerce, Marketplaces & Omnichannel. REST APIs, TypeScript SDKs, and production-ready Next.js storefront. Self-host it. Own your data. No vendor lock-in. Zero platform fees.

Added missing files

Mateusz Porębskib41f3f2d0925
diff --git a/bin/brakeman.sh b/bin/brakeman.sh
new file mode 100644
index 0000000000..da72f3e125
--- /dev/null
+++ b/bin/brakeman.sh
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+set -euxo pipefail
+
+./bin/build-ci.rb install
+bundle exec brakeman -p api/ --ignore-config api/brakeman.ignore --skip-files app/controllers/spree/api/v1/ --exit-on-warn --exit-on-error
+bundle exec brakeman -p core/ --ignore-config core/brakeman.ignore --exit-on-warn --exit-on-error
diff --git a/bin/bundle_ruby.sh b/bin/bundle_ruby.sh
new file mode 100644
index 0000000000..99d464b948
--- /dev/null
+++ b/bin/bundle_ruby.sh
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+set -euxo pipefail
+
+sudo apt-get update && sudo apt-get install libvips42
+bundle check || bundle install
+./bin/build-ci.rb install
diff --git a/bin/tests_coverage.sh b/bin/tests_coverage.sh
new file mode 100644
index 0000000000..880a411f50
--- /dev/null
+++ b/bin/tests_coverage.sh
@@ -0,0 +1,18 @@
+#!/bin/sh
+
+set -euxo pipefail
+
+mkdir -p tmp/
+curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./tmp/cc-test-reporter
+chmod +x ./tmp/cc-test-reporter
+
+export GIT_BRANCH="$CIRCLE_BRANCH"
+export GIT_COMMIT_SHA="$CIRCLE_SHA1"
+export GIT_COMMITTED_AT="$(date +%s)"
+
+./tmp/cc-test-reporter format-coverage -t simplecov -o tmp/codeclimate.api.json /tmp/workspace/simplecov/api/.resultset.json
+./tmp/cc-test-reporter format-coverage -t simplecov -o tmp/codeclimate.core.json /tmp/workspace/simplecov/core/.resultset.json
+./tmp/cc-test-reporter format-coverage -t simplecov -o tmp/codeclimate.emails.json /tmp/workspace/simplecov/emails/.resultset.json
+
+./tmp/cc-test-reporter sum-coverage tmp/codeclimate.*.json -p 3 -o tmp/codeclimate.total.json
+./tmp/cc-test-reporter upload-coverage -i tmp/codeclimate.total.json
\ No newline at end of file
diff --git a/bin/tests_database_ci.sh b/bin/tests_database_ci.sh
new file mode 100644
index 0000000000..7901979e26
--- /dev/null
+++ b/bin/tests_database_ci.sh
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+set -euxo pipefail
+
+if [$DB -eq "mysql"]
+then
+ sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 4EB27DB2A3B88B8B
+fi
+
+ls -l /tmp
+
+sudo apt-get update && sudo apt-get install libvips42
+bundle install
+./bin/build-ci.rb install
+./bin/build-ci.rb test