Skip to content

Instantly share code, notes, and snippets.

@azharuddinkhan3005
Last active January 10, 2020 06:52
Show Gist options
  • Save azharuddinkhan3005/48ab01bd66923233789b4682ddacb40f to your computer and use it in GitHub Desktop.
Save azharuddinkhan3005/48ab01bd66923233789b4682ddacb40f to your computer and use it in GitHub Desktop.
Docksal Linting
  • Take the latest pull from the master branch.

  • Then run the following command from the CLI, from the root of the CCF code directory on your local env.

    • fin npm install
    • This will take some time.
  • Then run the following commands:

    • fin eslint
    • fin sass-lint
    • When we run these individual commands then, we will get the follwing message for the first time:
      • ../.docksal/commands/sass-lint is not set to be executable. Fix automatically? [y/n]
      • then press y and proceed.
    • Then run the follwing command:
      • fin
      • this will print the list of available fin commands
      • we can find the eslint and sass-lint and phpcs commands in the Custom Commands section, which means these command are ready for use.
  • Usage:

    • JS linter
      • fin eslint [relative path of the JS file to check linting for]
    • Sass linter
      • fin sass-lint [relative path of the JS file to check linting for]
    • PHP code linter
      • fin phpcs [relative path of the JS file to check linting for]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment