From 582cac84210f6f4c5a0b7b807e6df9397ad1eca2 Mon Sep 17 00:00:00 2001 From: Joscha Date: Sat, 4 Mar 2023 18:45:07 +0100 Subject: [PATCH] Turn repo into flake --- CHANGELOG.md | 1 + README.md | 9 ++++++++ flake.lock | 63 ++++++++++++++++++++++++++++++++++++++++++++++++++++ flake.nix | 21 ++++++++++++++++++ 4 files changed, 94 insertions(+) create mode 100644 flake.lock create mode 100644 flake.nix diff --git a/CHANGELOG.md b/CHANGELOG.md index df432be..f9bf818 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -18,6 +18,7 @@ Procedure when bumping the version number: - `--verbose` flag - `json-stream` room export format - Option to export to stdout +- `flake.nix`, making cove available as a nix flake ### Changed - Respect colon-delimited emoji when calculating nick hue diff --git a/README.md b/README.md index e9b1ee8..4659f61 100644 --- a/README.md +++ b/README.md @@ -18,6 +18,15 @@ things in) won't automatically shrink. If it takes up too much space, try running `cove gc` and waiting for it to finish. This isn't done automatically because it can take quite a while. +## Installation + +At this point, cove is not available via any package manager. + +Cove is available as a Nix Flake. To try it out, you can use +```bash +$ nix run --override-input nixpkgs nixpkgs github:Garmelon/cove/latest +``` + ## Manual installation This section contains instructions on how to install cove by compiling it yourself. diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..ae07f3b --- /dev/null +++ b/flake.lock @@ -0,0 +1,63 @@ +{ + "nodes": { + "flake-utils": { + "locked": { + "lastModified": 1676283394, + "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "naersk": { + "inputs": { + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1671096816, + "narHash": "sha256-ezQCsNgmpUHdZANDCILm3RvtO1xH8uujk/+EqNvzIOg=", + "owner": "nix-community", + "repo": "naersk", + "rev": "d998160d6a076cfe8f9741e56aeec7e267e3e114", + "type": "github" + }, + "original": { + "owner": "nix-community", + "repo": "naersk", + "type": "github" + } + }, + "nixpkgs": { + "locked": { + "lastModified": 1677950239, + "narHash": "sha256-TAX92aTbRyRD8dF6luUyYdSXPuULpntWQukknm2AliM=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "5aee86add3e576f6b1862d1e6c005e63c409f669", + "type": "github" + }, + "original": { + "owner": "NixOS", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "flake-utils": "flake-utils", + "naersk": "naersk", + "nixpkgs": "nixpkgs" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..17b2241 --- /dev/null +++ b/flake.nix @@ -0,0 +1,21 @@ +{ + description = "TUI client for euphoria.io, a threaded real-time chat platform"; + + inputs = { + nixpkgs.url = "github:NixOS/nixpkgs"; + flake-utils.url = "github:numtide/flake-utils"; + + naersk.url = "github:nix-community/naersk"; + naersk.inputs.nixpkgs.follows = "nixpkgs"; + }; + + outputs = { self, nixpkgs, flake-utils, naersk }: flake-utils.lib.eachDefaultSystem (system: + let + pkgs = import nixpkgs { inherit system; }; + naersk' = pkgs.callPackage naersk { }; + in + rec { + packages.default = naersk'.buildPackage { src = ./.; }; + } + ); +}