summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorwinniehell <git@winniehell.de>2016-07-22 22:54:58 +0200
committerwinniehell <git@winniehell.de>2016-10-26 10:00:55 +0200
commite5a0d41db0c2871cc9b229aab40de19bdabe1d9e (patch)
tree61df949191908e8ef59baf0bf73e1c9f4f93d9f7
parent3d174c7198f103cdedd7c7ffb7678aff1dd4de33 (diff)
downloadgitlab-ce-e5a0d41db0c2871cc9b229aab40de19bdabe1d9e.tar.gz
add ESLint
ESLint config: https://github.com/airbnb/javascript
-rw-r--r--.eslintignore4
-rw-r--r--.eslintrc23
-rw-r--r--.gitignore1
-rw-r--r--package.json14
4 files changed, 42 insertions, 0 deletions
diff --git a/.eslintignore b/.eslintignore
new file mode 100644
index 00000000000..453747e14e1
--- /dev/null
+++ b/.eslintignore
@@ -0,0 +1,4 @@
+/public/
+/tmp/
+/vendor/
+
diff --git a/.eslintrc b/.eslintrc
new file mode 100644
index 00000000000..16eb18ecba2
--- /dev/null
+++ b/.eslintrc
@@ -0,0 +1,23 @@
+{
+ "extends": "airbnb",
+ "globals": {
+ "$": false,
+ "_": false,
+ "beforeEach": false,
+ "d3": false,
+ "define": false,
+ "describe": false,
+ "document": false,
+ "expect": false,
+ "fixture": false,
+ "gl": false,
+ "it": false,
+ "jQuery": false,
+ "Mousetrap": false,
+ "spyOn": false,
+ "spyOnEvent": false,
+ "Turbolinks": false,
+ "window": false
+ }
+}
+
diff --git a/.gitignore b/.gitignore
index 9166512606d..6a1002621f4 100644
--- a/.gitignore
+++ b/.gitignore
@@ -37,6 +37,7 @@
/doc/code/*
/dump.rdb
/log/*.log*
+/node_modules/
/nohup.out
/public/assets/
/public/uploads.*
diff --git a/package.json b/package.json
new file mode 100644
index 00000000000..942b2113e65
--- /dev/null
+++ b/package.json
@@ -0,0 +1,14 @@
+{
+ "private": true,
+ "scripts": {
+ "eslint": "eslint .",
+ "eslint-fix": "eslint --fix ."
+ },
+ "devDependencies": {
+ "eslint": "^3.1.1",
+ "eslint-config-airbnb": "^12.0.0",
+ "eslint-plugin-import": "^2.0.1",
+ "eslint-plugin-jsx-a11y": "^2.2.3",
+ "eslint-plugin-react": "^6.4.1"
+ }
+}