From 808e929a7160e97bdb4b23a75ab39b1ba74109f0 Mon Sep 17 00:00:00 2001 From: Rok Garbas Date: Thu, 7 Apr 2022 23:36:07 +0200 Subject: [PATCH] Update flake inputs (#467) * Add github workflow to update flake inputs weekly also including initial flake.lock update. * Use a different nixpkgs for the time being (until PR is merged) --- .github/workflows/update-flake-lock.yml | 19 +++++++++++++++++++ flake.lock | 21 +++++++++++---------- flake.nix | 16 ++++++++-------- 3 files changed, 38 insertions(+), 18 deletions(-) create mode 100644 .github/workflows/update-flake-lock.yml diff --git a/.github/workflows/update-flake-lock.yml b/.github/workflows/update-flake-lock.yml new file mode 100644 index 0000000..73d8018 --- /dev/null +++ b/.github/workflows/update-flake-lock.yml @@ -0,0 +1,19 @@ +name: update-flake-lock +on: + workflow_dispatch: # allows manual triggering + schedule: + - cron: '0 0 * * 0' # runs weekly on Sunday at 00:00 + +jobs: + lockfile: + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v3 + - name: Install Nix + uses: cachix/install-nix-action@v16 + with: + extra_nix_config: | + access-tokens = github.com=${{ secrets.GITHUB_TOKEN }} + - name: Update flake.lock + uses: DeterminateSystems/update-flake-lock@v8 diff --git a/flake.lock b/flake.lock index 19cd175..1a96b76 100644 --- a/flake.lock +++ b/flake.lock @@ -2,11 +2,11 @@ "nodes": { "flake-utils": { "locked": { - "lastModified": 1644229661, - "narHash": "sha256-1YdnJAsNy69bpcjuoKdOYQX0YxZBiCYZo4Twxerqv7k=", + "lastModified": 1648297722, + "narHash": "sha256-W+qlPsiZd8F3XkzXOzAoR+mpFqzm3ekQkJNa+PIh1BQ=", "owner": "numtide", "repo": "flake-utils", - "rev": "3cecb5b042f7f209c56ffd8371b2711a290ec797", + "rev": "0f8662f1319ad6abf89b3380dd2722369fc51ade", "type": "github" }, "original": { @@ -17,17 +17,18 @@ }, "nixpkgs": { "locked": { - "lastModified": 1642903813, - "narHash": "sha256-0lNfGW8sNfyTrixoQhVG00Drl/ECaf5GbfKAQ1ZDoyE=", - "owner": "NixOS", + "lastModified": 1649314464, + "narHash": "sha256-dU/Ed+VXtCAWbwRtHg9KPnskhRypB0nMb9Av/OOrV84=", + "owner": "aforemny", "repo": "nixpkgs", - "rev": "689b76bcf36055afdeb2e9852f5ecdd2bf483f87", + "rev": "3d88f74c9d13e599d1bd3633e8afb197b8378071", "type": "github" }, "original": { - "id": "nixpkgs", - "ref": "nixos-unstable", - "type": "indirect" + "owner": "aforemny", + "ref": "fix/elm-format", + "repo": "nixpkgs", + "type": "github" } }, "root": { diff --git a/flake.nix b/flake.nix index 742dc45..027200f 100644 --- a/flake.nix +++ b/flake.nix @@ -1,15 +1,15 @@ { description = "Code behind search.nixos.org"; - nixConfig = { - extra-substituters = [ "https://nixos-search.cachix.org" ]; - extra-trusted-public-keys = [ "nixos-search.cachix.org-1:1HV3YF8az4fywnH+pAd+CXFEdpTXtv9WpoivPi+H70o=" ]; - }; + nixConfig.extra-substituters = [ "https://nixos-search.cachix.org" ]; + nixConfig.extra-trusted-public-keys = [ "nixos-search.cachix.org-1:1HV3YF8az4fywnH+pAd+CXFEdpTXtv9WpoivPi+H70o=" ]; - inputs = { - nixpkgs.url = "nixpkgs/nixos-unstable"; - flake-utils.url = "github:numtide/flake-utils"; - }; + # TODO: follow nixos-unstable once elm-format fix is merged and release + # on nixos-unstable channels: + # https://github.com/NixOS/nixpkgs/pull/167642 + # inputs.nixpkgs.url = "nixpkgs/nixos-unstable"; + inputs.nixpkgs.url = "github:aforemny/nixpkgs/fix/elm-format"; + inputs.flake-utils.url = "github:numtide/flake-utils"; outputs = { self , nixpkgs