All Projects → stefanoeb → eslint-action

stefanoeb / eslint-action

Licence: MIT license
Github action that runs ESLint on javascript code.

Programming Languages

shell
77523 projects
Dockerfile
14818 projects

Projects that are alternatives of or similar to eslint-action

auth
A GitHub Action for authenticating to Google Cloud.
Stars: ✭ 567 (+600%)
Mutual labels:  actions
azure-static-website-deploy
Deploys static website to Azure Storage
Stars: ✭ 18 (-77.78%)
Mutual labels:  actions
winrar-keygen
Principle of WinRAR key generation.
Stars: ✭ 398 (+391.36%)
Mutual labels:  actions
do-spaces-action
📦Upload directories/files to DigitalOcean Spaces via GitHub Actions. Supports package/library versioning.
Stars: ✭ 30 (-62.96%)
Mutual labels:  actions
composer-action
Docker and GitHub Actions for Composer
Stars: ✭ 34 (-58.02%)
Mutual labels:  actions
set-env-to-github env
A migration tools convert `::set-env`/`::set-output`/`::save-state` to $GITHUB_ENV/$GITHUB_OUTPUT/$GITHUB_STATE on GitHub Actions.
Stars: ✭ 27 (-66.67%)
Mutual labels:  actions
gh-actions-html-table-generator
Read from a json file and write to the README
Stars: ✭ 29 (-64.2%)
Mutual labels:  actions
juejin-actions
掘金每天自动签到 github actions 。组织了每周一起学习200行左右的【源码共读】活动,感兴趣可以加我微信 ruochuan12 参与。
Stars: ✭ 47 (-41.98%)
Mutual labels:  actions
gcloud-login-action
A Github Action which can be used to authenticate with Google Cloud Container Registry
Stars: ✭ 21 (-74.07%)
Mutual labels:  actions
dont-waste-your-ducking-time
🐓 An opinionated guide on how to test Redux ducks
Stars: ✭ 28 (-65.43%)
Mutual labels:  actions
issue-action
github action for github issue
Stars: ✭ 58 (-28.4%)
Mutual labels:  actions
deploy-appengine
A GitHub Action that deploys source code to Google App Engine.
Stars: ✭ 184 (+127.16%)
Mutual labels:  actions
launchbar
Actions repository for LaunchBar 6
Stars: ✭ 65 (-19.75%)
Mutual labels:  actions
setup-meteor
Set up your GitHub Actions workflow with a specific version of Meteor.js
Stars: ✭ 17 (-79.01%)
Mutual labels:  actions
material-about
An about screen to use in your Mobile apps.
Stars: ✭ 37 (-54.32%)
Mutual labels:  actions
innersource-crawler
This project creates a repos.json that can be utilized by the SAP InnerSource Portal.
Stars: ✭ 24 (-70.37%)
Mutual labels:  actions
action-lgtm-reaction
GitHub Action to send LGTM reaction
Stars: ✭ 62 (-23.46%)
Mutual labels:  actions
actions-suggest-related-links
A GitHub Action to suggest related or similar issues, documents, and links. Based on the power of NLP and fastText.
Stars: ✭ 23 (-71.6%)
Mutual labels:  actions
actionlint
Static checker for GitHub Actions workflow files
Stars: ✭ 1,385 (+1609.88%)
Mutual labels:  actions
yaml-update-action
Update YAML property with dynamic values
Stars: ✭ 81 (+0%)
Mutual labels:  actions

⚠️⚠️⚠️ You don't need this action ⚠️⚠️⚠️

Github Actions have everything that you need to run your eslint out of the box now, to do that simply use the run commands like so:

name: CI
on: push
jobs:
  build:
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@v2
    - name: Install modules
      run: yarn
    - name: Run ESLint
      run: eslint . --ext .js,.jsx,.ts,.tsx

This action executes ESLint linter on specified javascript files without any previous action/build step or Docker required.

Prerequisites

ESLint

You must have the ESLint running locally for the action to execute. It will use the same rules as you do locally. More info on the ESLint getting started guide

Usage

main.yml

Add to your existing main.yml file or create a new file named .github/workflows/lint.yml and copy over one of the examples below to your new workflow file

This is the simplest example to get it running:

name: Lint

on: [push]

jobs:
  eslint:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v1
      - uses: stefanoeb/[email protected]

By default it will run ESLint through all the files in the project. But you can also specify a glob of files to lint using the with: argument on your YAML file. The example below shows ESLint running only on the files under the src/ folder:

name: Lint

on: [push]

jobs:
  eslint:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v1
      - uses: stefanoeb/[email protected]
        with:
          files: src/

If there is no previous step installing the necessary modules, this action will execute a yarn install or npm install automatically.

License

The Dockerfile and associated scripts and documentation in this project are released under the MIT License.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].