From f0bdefce7480c0c19c4db5eb131274b505f5a3ae Mon Sep 17 00:00:00 2001 From: Rafael dos Santos Date: Tue, 24 Sep 2019 15:10:35 -0300 Subject: [PATCH] fe|FEAT: Add circleCI configuration (#3) --- .circleci/config.yml | 9 +-------- Makefile | 17 +++++------------ 2 files changed, 6 insertions(+), 20 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 4742b09..3c7898e 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -3,16 +3,9 @@ version: 2 jobs: build: docker: - - image: circleci/golang:1.11 - - working_directory: /go/src/github.com/globocom/huskyCI-dashboard - + - image: circleci/node steps: - checkout - - run: - name: "Tests" - command: | - make test - run: name: "Check security using Yarn Audit" command: | diff --git a/Makefile b/Makefile index ad68bf0..6792c03 100644 --- a/Makefile +++ b/Makefile @@ -1,10 +1,6 @@ .SILENT: .DEFAULT_GOAL := help -NPM ?= $(shell which npm) -YARN ?= $(shell which yarn) -PKG_MANAGER ?= $(if $(YARN),$(YARN),$(NPM)) - COLOR_RESET = \033[0m COLOR_COMMAND = \033[36m COLOR_YELLOW = \033[33m @@ -15,22 +11,19 @@ PROJECT := huskyCI-dashboard ## Installs locally using install command. install: - @${PKG_MANAGER} install + yarn install ## Runs locally using start command. run: - @${PKG_MANAGER} start + yarn start ## Checks for vulnerabilities using audit command. check-sec: - @${PKG_MANAGER} audit - -## Runs unit tests using test command. -unit: - @${PKG_MANAGER} test + yarn audit ## Runs a full test into project. -test: unit +test: + yarn test ## Shows this help message. help: