IMPORTANT: This gist should be considered archived. You can find the currently maintained instructions at https://github.com/dev-academy-programme/computer-setup.
This setup uses a global eslint installation. VS Code will use a locally installed/project-based ESLint installation, but if it doesn't find one, it will use this global one.
The following steps are best to be applied in order.
npm install -g \
git-iam \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected]
- ESLint
- vscode-icons
File ➡️ Preferences ➡️ Settings
{
"editor.tabSize": 2,
"workbench.iconTheme": "vscode-icons"
}
This enables CMD+b
to automatically fix as many linting errors/warnings as it can with a single shortcut.
File ➡️ Preferences ➡️ Keyboard Shortcuts (and then click on keybindings.json
). Use this as the contents.
[
{
"key": "cmd+b",
"command": "eslint.executeAutofix",
"when": "editorFocus"
}
]
{
"parser": "babel-eslint",
"env": {
"browser": true,
"node": true,
"jest": true
},
"extends": [
"eslint:recommended",
"plugin:react/recommended",
"standard"
],
"plugins": [
"standard",
"promise"
],
"rules": {
"eol-last": ["error", "always"],
"no-multiple-empty-lines": [
"error", { "max": 1, "maxEOF": 0, "maxBOF": 0 }
],
"object-curly-spacing": [2, "always"],
"react/prop-types": "off"
},
"settings": {
"react": { "version": "detect" }
}
}
- Edit the appropriate cohort file at https://github.com/enspiral-dev-academy/students with student details
- In GitHub, navigate to the file, click the "Raw" button and copy the URL to your clipboard
- Initialise
git-iam
with the cohort's URL:git-iam --init [URL on your clipboard]
- Test that it works:
git iam [a name from the list]