pgAdmin 4 commit: Introducing custom linter script for javascript files

From: Ashesh Vashi <ashesh(dot)vashi(at)enterprisedb(dot)com>
To: pgadmin-hackers(at)postgresql(dot)org
Subject: pgAdmin 4 commit: Introducing custom linter script for javascript files
Date: 2018-01-17 07:54:46
Message-ID: E1ebiYY-0008DB-9A@gothos.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

Introducing custom linter script for javascript files.
Also, changed the 'linter' yarn-command to use this script.

This script will run the 'eslint' against all the static javascripts,
found under pgadmin and regression directories of source (excepts
'vendor', 'generated'). It also allows to run the 'eslint' against
specific javascript file[s].

In order to run eslint on all static javascript files, run the following command:
yarn run linter
node pga_eslint

In order to run eslint on specific files, run the following command:
yarn run linter --file <filename> [<filename>]
node pga_script --file <filename> [<filename>]

In order to provide eslint specific commands, run the following command:
yarn run linter [--file <filename> [<filename>]] --eslint-options
node pga_script [--file <filename> [<filename>]] --eslint-options

i.e.
yarn run linter --fix
yarn run linter --debug
node pga_eslint --fix --debug pgadmin/static/js/pgadmin.js

Branch
------
master

Details
-------
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=4d8b7556f8b780b804017d754726a60490985f4f

Modified Files
--------------
web/package.json | 2 +-
web/pga_eslint.js | 43 +++++++++++++++++++++++++++++++++++++++++++
2 files changed, 44 insertions(+), 1 deletion(-)

Browse pgadmin-hackers by date

  From Date Subject
Next Message Dave Page 2018-01-17 11:28:02 Re: Module-wise Keyboard preferences
Previous Message Khushboo Vashi 2018-01-17 06:55:49 Re: [pgAdmin4][Patch]: RM #2904: As a visually impaired user I need all buttons in the application to have appropriate tooltips for my screen reader to interpret