From 0bc731ee1b0d065c5c39445372286d16a407cd31 Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Thu, 4 Jul 2019 11:19:40 +0100 Subject: feat(build): Add WORKSPACE configuration for Bazel This sets up Haskell & Nix rules in the workspace. --- WORKSPACE | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 WORKSPACE diff --git a/WORKSPACE b/WORKSPACE new file mode 100644 index 000000000000..bb69b80a3c56 --- /dev/null +++ b/WORKSPACE @@ -0,0 +1,39 @@ +# -*- mode: bazel; -*- +# +# This workspace configuration loads all Bazel rule sets that need to +# be available in the entire repository. + +workspace(name = "tazjin_monorepo") + +# SECTION: Nix + +local_repository( + name = "io_tweag_rules_nixpkgs", + path = "third_party/bazel/rules_nixpkgs", +) + +load("@io_tweag_rules_nixpkgs//nixpkgs:nixpkgs.bzl", "nixpkgs_local_repository", "nixpkgs_package") + +# SECTION: Haskell + +local_repository( + name = "io_tweag_rules_haskell", + path = "third_party/bazel/rules_haskell", +) + +load( + "@io_tweag_rules_haskell//haskell:repositories.bzl", + "haskell_repositories" +) + +haskell_repositories() + +load( + "@io_tweag_rules_haskell//haskell:nixpkgs.bzl", + "haskell_register_ghc_nixpkgs", +) + +haskell_register_ghc_nixpkgs( + version = "8.6.4", + repositories = { "nixpkgs": "default.nix" } +) -- cgit 1.4.1