diff --git a/.eslintrc b/.eslintrc index 3e48e369..24c0ef30 100644 --- a/.eslintrc +++ b/.eslintrc @@ -1,3 +1,7 @@ { - "extends": "./packages/eslint-config/index.js" + "extends": "./packages/eslint-config/index.js", + "rules": { + "new-cap": 0, + "no-console": 0 + } } diff --git a/packages/cp-gql-mock-server/src/resolvers.js b/packages/cp-gql-mock-server/src/resolvers.js index 5a356539..89270099 100644 --- a/packages/cp-gql-mock-server/src/resolvers.js +++ b/packages/cp-gql-mock-server/src/resolvers.js @@ -32,18 +32,21 @@ const getDeploymentGroups = query => .filter(find(cleanQuery(query))) .map(getDeploymentGroupServices); -const getPortal = () => Object.assign({}, portal, { - datacenter, - deploymentGroups: getDeploymentGroups() -}); +const getPortal = () => + Object.assign({}, portal, { + datacenter, + deploymentGroups: getDeploymentGroups() + }); const getServices = query => services.filter(find(query)).map(getDeploymentGroupServices); module.exports = { portal: (options, request, fn) => fn(null, getPortal()), - deploymentGroups: (options, request, fn) => fn(null, getDeploymentGroups(options)), - deploymentGroup: (options, request, fn) => fn(null, getDeploymentGroups(options).shift()), + deploymentGroups: (options, request, fn) => + fn(null, getDeploymentGroups(options)), + deploymentGroup: (options, request, fn) => + fn(null, getDeploymentGroups(options).shift()), services: (options, request, fn) => fn(null, getServices()), service: (options, request, fn) => fn(null, getServices(options).shift()) }; diff --git a/packages/pseudo-yaml-ast/package.json b/packages/pseudo-yaml-ast/package.json index e500f712..ccef879e 100644 --- a/packages/pseudo-yaml-ast/package.json +++ b/packages/pseudo-yaml-ast/package.json @@ -24,7 +24,8 @@ "dist" ], "scripts": { - "lint": "eslint . --fix --format=tap", + "lint": "eslint . --fix", + "lint-ci": "eslint . --format junit --output-file $CIRCLE_TEST_REPORTS/lint/pseudo-yaml-ast.xml", "test:run": "cross-env NODE_ENV=test nyc --reporter=lcov --reporter=text ava", "test-ci:run": "cross-env NODE_ENV=test nyc --reporter=lcov --reporter=text ava --tap | tap-xunit > $CIRCLE_TEST_REPORTS/test/pseudo-yaml-ast.xml", "test": "redrun build test:run", diff --git a/packages/ui-toolkit/package.json b/packages/ui-toolkit/package.json index d787fa73..59a908da 100644 --- a/packages/ui-toolkit/package.json +++ b/packages/ui-toolkit/package.json @@ -9,7 +9,7 @@ "scripts": { "lint:css": "exit 0", "lint-ci:css": "exit 0", - "lint:js": "eslint . --fix --format=tap", + "lint:js": "eslint . --fix", "lint-ci:js": "eslint . --format junit --output-file $CIRCLE_TEST_REPORTS/lint/ui-toolkit.xml", "lint": "redrun -s lint:*", "lint-ci": "redrun -s lint-ci:*", diff --git a/packages/ui-toolkit/src/tooltip/button.js b/packages/ui-toolkit/src/tooltip/button.js index c6ac0ed1..0439e259 100644 --- a/packages/ui-toolkit/src/tooltip/button.js +++ b/packages/ui-toolkit/src/tooltip/button.js @@ -34,7 +34,7 @@ const StyledButton = styled(Button)` } `; -const TooltipButton = (props) => ( +const TooltipButton = props => (
  • diff --git a/packages/ui-toolkit/src/tooltip/index.js b/packages/ui-toolkit/src/tooltip/index.js index ca4ab204..51a302c5 100644 --- a/packages/ui-toolkit/src/tooltip/index.js +++ b/packages/ui-toolkit/src/tooltip/index.js @@ -8,10 +8,10 @@ import { border, borderRadius, tooltipShadow } from '../boxes'; const StyledContainer = styled.div` position: absolute; - top: ${(props) => props.top}; - left: ${(props) => props.left}; - bottom: ${(props) => props.bottoms}; - right: ${(props) => props.right}; + top: ${props => props.top}; + left: ${props => props.left}; + bottom: ${props => props.bottoms}; + right: ${props => props.right}; `; const StyledList = styled.ul` @@ -61,14 +61,9 @@ const Tooltip = ({ bottom = 'auto', right = 'auto' }) => ( - + - { children } + {children} ); @@ -79,6 +74,6 @@ Tooltip.propTypes = { left: PropTypes.number, bottom: PropTypes.number, right: PropTypes.number -} +}; export default Tooltip; diff --git a/scripts/release b/scripts/release index bcde8924..6c668e1b 100755 --- a/scripts/release +++ b/scripts/release @@ -344,15 +344,12 @@ const tasks = [ const tagName = `${pkg.name}-${releaseType}@${version}`; const tagBody = `${EOL}${lastCommits}`; - // eslint-disable-next-line no-console console.log( `${prefix}${chalk.yellow('Tag Name: ')}\n${prefix}${prefix}${chalk.dim(tagName)}` ); - // eslint-disable-next-line no-console console.log(`${prefix}${chalk.yellow('Tag Description: ')}`); - // eslint-disable-next-line no-console console.log( `${chalk.dim(lastCommits .split(/\n/) @@ -441,12 +438,10 @@ const run = (tasks = [], ctx = {}, prefix = '') => } if (isString(title)) { - // eslint-disable-next-line no-console console.log(`${prefix}${chalk.green(figures.arrowRight)} ${title}`); } if (isString(description)) { - // eslint-disable-next-line no-console console.log( `${chalk.dim(`${prefix}${figures.arrowRight} ${description}`)}` ); @@ -459,10 +454,8 @@ const run = (tasks = [], ctx = {}, prefix = '') => const [err, nCtx] = await intercept(task(context)); if (err) { - // eslint-disable-next-line no-console console.log(`${chalk.red(figures.cross)} ${chalk.dim(err.message)}`); - // eslint-disable-next-line no-console console.log( `${chalk.dim(err.stack.replace(`Error: ${err.message}`, '').trim())}` );