-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathflake.nix.works
More file actions
33 lines (28 loc) · 932 Bytes
/
flake.nix.works
File metadata and controls
33 lines (28 loc) · 932 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
{
description = "Flake: Just fetch Flutter";
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
outputs =
{ self, nixpkgs }:
{
defaultPackage.x86_64-linux =
with import nixpkgs { system = "x86_64-linux"; };
let
FLUTTER_VERSION = "3.27.1";
FILENAME = "flutter_linux_${FLUTTER_VERSION}-stable.tar.xz";
FETCH_URL = "https://storage.googleapis.com/flutter_infra_release/releases/stable/linux/${FILENAME}";
flutterArchive = fetchurl {
url = "${FETCH_URL}";
sha256 = "sha256-YUl+tkzXs6qZypkRzNkhyNq3mv2QnKHJ/5VGBn689so=";
executable = false;
};
in
stdenv.mkDerivation {
name = "flutter";
src = self;
buildPhase = ''
tar -xvf "${flutterArchive}"
'';
installPhase = "mkdir -p $out; cp -ar flutter/* $out";
};
};
}