aliases:
    - &python_settings
      types: [python]
      exclude: >
          (?x)^(
            .+/migrations/.+|
          )$

repos:
    - repo: https://github.com/pre-commit/mirrors-isort
      rev: v4.3.21
      hooks:
          - <<: *python_settings
            id: isort
    - repo: https://github.com/python/black
      rev: 19.3b0
      hooks:
          - <<: *python_settings
            id: black
            language_version: python3.7
    - repo: https://gitlab.com/pycqa/flake8
      rev: 3.7.8
      hooks:
          - <<: *python_settings
            id: flake8
    - repo: https://github.com/prettier/prettier
      rev: 1.18.2
      hooks:
          - id: prettier
            files: 'frontend/.*\.(js|jsx|ts|tsx)$'
    - repo: https://github.com/pre-commit/pre-commit-hooks
      rev: v2.2.3
      hooks:
          - id: end-of-file-fixer
            files: '^.*\.(py|mjml|js|jsx|tf|tfvars|conf)$'
          - id: file-contents-sorter
            files: "^requirements(-test)?.in$"

    - repo: local
      hooks:
          - id: eslint
            name: eslint
            types: [file]
            files: 'frontend/.*\.(js|jsx|ts|tsx)$'
            entry: bash -c 'cd frontend && yarn precommit-lint "$@"'
            language: system

aliases:
    - &python_settings
      types: [python]
      exclude: >
          (?x)^(
            .+/migrations/.+|
          )$

repos:
    - repo: https://github.com/pre-commit/mirrors-isort
      rev: v4.3.21
      hooks:
          - <<: *python_settings
            id: isort
    - repo: https://github.com/python/black
      rev: 19.3b0
      hooks:
          - <<: *python_settings
            id: black
            language_version: python3.7
    - repo: https://gitlab.com/pycqa/flake8
      rev: 3.7.8
      hooks:
          - <<: *python_settings
            id: flake8
    - repo: https://github.com/prettier/prettier
      rev: 1.19.1
      hooks:
          - id: prettier
            files: 'frontend/.*\.(js|jsx|ts|tsx)$'
    - repo: https://github.com/pre-commit/pre-commit-hooks
      rev: v2.2.3
      hooks:
          - id: end-of-file-fixer
            files: '^.*\.(py|mjml|js|jsx|tf|tfvars|conf)$'
          - id: file-contents-sorter
            files: "^requirements(-test)?.in$"

    - repo: local
      hooks:
          - id: eslint
            name: eslint
            types: [file]
            files: 'frontend/.*\.(js|jsx|ts|tsx)$'
            entry: bash -c 'cd frontend && yarn precommit-lint "$@"'
            language: system

Fix prettier version in pre-commit
Fix prettier version in pre-commit
