diff --git a/.envrc b/.envrc deleted file mode 100644 index c23bb91..0000000 --- a/.envrc +++ /dev/null @@ -1,7 +0,0 @@ -use_flake() { - watch_file flake.nix - watch_file flake.lock - eval "$(nix print-dev-env)" -} - -use flake diff --git a/.gitignore b/.gitignore index d787b70..ea8c4bf 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1 @@ /target -/result diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml deleted file mode 100644 index cda3975..0000000 --- a/.pre-commit-config.yaml +++ /dev/null @@ -1,20 +0,0 @@ -repos: -- repo: 'local' - hooks: - - id: 'nixpkgs-fmt' - name: 'nixpkgs-fmt' - description: 'Format nix code with nixpkgs-fmt' - entry: 'nixpkgs-fmt' - language: 'system' - files: '\.nix$' - always_run: true -- repo: 'https://github.com/pre-commit/pre-commit-hooks' - rev: 'v2.3.0' - hooks: - - id: 'trailing-whitespace' - - id: 'end-of-file-fixer' - - id: 'check-yaml' -- repo: 'https://github.com/jumanjihouse/pre-commit-hooks' - rev: '2.1.4' - hooks: - - id: 'forbid-binary' diff --git a/default.nix b/default.nix deleted file mode 100644 index 873ece4..0000000 --- a/default.nix +++ /dev/null @@ -1,13 +0,0 @@ -(import - ( - let - lock = builtins.fromJSON (builtins.readFile ./flake.lock); - in - fetchTarball { - url = "https://github.com/edolstra/flake-compat/archive/${lock.nodes.flake-compat.locked.rev}.tar.gz"; - sha256 = lock.nodes.flake-compat.locked.narHash; - } - ) - { - src = ./.; - }).defaultNix diff --git a/flake.lock b/flake.lock deleted file mode 100644 index c0cf2ff..0000000 --- a/flake.lock +++ /dev/null @@ -1,99 +0,0 @@ -{ - "nodes": { - "flake-compat": { - "flake": false, - "locked": { - "lastModified": 1606424373, - "narHash": "sha256-oq8d4//CJOrVj+EcOaSXvMebvuTkmBJuT5tzlfewUnQ=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "99f1c2157fba4bfe6211a321fd0ee43199025dbf", - "type": "github" - }, - "original": { - "owner": "edolstra", - "repo": "flake-compat", - "type": "github" - } - }, - "flake-utils": { - "locked": { - "lastModified": 1614513358, - "narHash": "sha256-LakhOx3S1dRjnh0b5Dg3mbZyH0ToC9I8Y2wKSkBaTzU=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "5466c5bbece17adaab2d82fae80b46e807611bf3", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "mozillapkgs": { - "flake": false, - "locked": { - "lastModified": 1603906276, - "narHash": "sha256-RsNPnEKd7BcogwkqhaV5kI/HuNC4flH/OQCC/4W5y/8=", - "owner": "mozilla", - "repo": "nixpkgs-mozilla", - "rev": "8c007b60731c07dd7a052cce508de3bb1ae849b4", - "type": "github" - }, - "original": { - "owner": "mozilla", - "repo": "nixpkgs-mozilla", - "type": "github" - } - }, - "naersk": { - "inputs": { - "nixpkgs": [ - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1614785451, - "narHash": "sha256-TPw8kQvr2UNCuvndtY+EjyXp6Q5GEW2l9UafXXh1XmI=", - "owner": "nmattia", - "repo": "naersk", - "rev": "e0fe990b478a66178a58c69cf53daec0478ca6f9", - "type": "github" - }, - "original": { - "owner": "nmattia", - "ref": "master", - "repo": "naersk", - "type": "github" - } - }, - "nixpkgs": { - "locked": { - "lastModified": 1616670887, - "narHash": "sha256-wn+l9qJfR5sj5Gq4DheJHAcBDfOs9K2p9seW2f35xzs=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "c0e881852006b132236cbf0301bd1939bb50867e", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "root": { - "inputs": { - "flake-compat": "flake-compat", - "flake-utils": "flake-utils", - "mozillapkgs": "mozillapkgs", - "naersk": "naersk", - "nixpkgs": "nixpkgs" - } - } - }, - "root": "root", - "version": 7 -} diff --git a/flake.nix b/flake.nix deleted file mode 100644 index acd7f57..0000000 --- a/flake.nix +++ /dev/null @@ -1,55 +0,0 @@ -{ - inputs = { - naersk = { - url = "github:nmattia/naersk/master"; - inputs.nixpkgs.follows = "nixpkgs"; - }; - mozillapkgs = { - url = "github:mozilla/nixpkgs-mozilla"; - flake = false; - }; - nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - flake-utils.url = "github:numtide/flake-utils"; - flake-compat = { - url = "github:edolstra/flake-compat"; - flake = false; - }; - }; - - outputs = { self, naersk, mozillapkgs, nixpkgs, flake-utils, ... }: - flake-utils.lib.eachDefaultSystem (system: - let - pkgs = import nixpkgs { inherit system; }; - - mozilla = pkgs.callPackage (mozillapkgs + "/package-set.nix") { }; - rustNightly = (mozilla.rustChannelOf { - date = "2021-03-29"; - channel = "nightly"; - sha256 = "sha256-Y94CnslybZgiZlNVV6Cg0TUPV2OeDXakPev1kqdt9Kk="; - }).rust; - - naersk-lib = pkgs.callPackage naersk { - cargo = rustNightly; - rustc = rustNightly; - }; - in - { - defaultPackage = naersk-lib.buildPackage ./.; - - defaultApp = flake-utils.lib.mkApp { - drv = self.defaultPackage."${system}"; - }; - - devShell = pkgs.mkShell { - buildInputs = with pkgs; [ - nixpkgs-fmt - pre-commit - rustPackages.clippy - rustNightly - rustfmt - ]; - - RUST_SRC_PATH = pkgs.rustPlatform.rustLibSrc; - }; - }); -} diff --git a/shell.nix b/shell.nix deleted file mode 100644 index 9eb132a..0000000 --- a/shell.nix +++ /dev/null @@ -1,13 +0,0 @@ -(import - ( - let - lock = builtins.fromJSON (builtins.readFile ./flake.lock); - in - fetchTarball { - url = "https://github.com/edolstra/flake-compat/archive/${lock.nodes.flake-compat.locked.rev}.tar.gz"; - sha256 = lock.nodes.flake-compat.locked.narHash; - } - ) - { - src = ./.; - }).shellNix