Coder Social home page Coder Social logo

action-eslint's Introduction

Discord Status Weekly Stats

I write code.

action-eslint's People

Contributors

bolismauro avatar chrisdrackett avatar dependabot-preview[bot] avatar icrawl avatar oupsla avatar renovate[bot] avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

action-eslint's Issues

Need to be able to set working-directory

When using this action in a monorepo, I get the following error

##[error]Cannot find module '/home/runner/work/OWNER/REPO/node_modules/eslint'

This is because my app root is not in the root of my repo.

Monorepo support

It would be nice if src/ wasn't hardcoded:

const report = cli.executeOnFiles(files || ['src']);

I would like to be able to run this in a monorepo (yarn workspaces), and configure what folders to run the checks in.

No files matching the pattern "src" were found

Thanks for the project! I started running into the following error after the latest update:

Added matchers: 'eslint-stylish'. Problem matchers scan action output for known warning or error strings and report these inline.
/opt/hostedtoolcache/node/12.14.1/x64/bin/node /home/runner/work/calm/calm/node_modules/eslint/bin/eslint --ext js,jsx,ts,tsx src
Oops! Something went wrong! :(
ESLint: 6.7.2.
No files matching the pattern "src" were found.
Please check for typing mistakes in the pattern.
##[error]Node run failed with exit code 1

I took a look at eslint-stylish to see if that might be the cause but nothing stood out to me. I think the eslint command with the src at the end is most likely the culprit.

Here is my lint.yml file:

name: ESLint

on:
  pull_request:
    branches:
      - master

jobs:
  eslint:
    name: Lint updated files
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v1
      - name: install node v12
        uses: actions/setup-node@v1
        with:
          node-version: 12
      - name: yarn install
        run: yarn install
        env:
          DATABASE_URL: ${{ secrets.DATABASE_URL }}
      - name: eslint
        uses: icrawl/action-eslint@v1
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
        with:
          job-name: eslint
          default-dir: '.'

Setting it back to uses: icrawl/[email protected] made eslint run again for me.

accept normal eslint glob?

Right now because of the split on , I can't use a glob of say: **/*.{js,jsx,ts,tsx} which is the glob I use linting locally.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.