Skip to content

Commit 397e54a

Browse files
committed
Fix all packages
1 parent e6c4da3 commit 397e54a

File tree

3 files changed

+8
-6
lines changed

3 files changed

+8
-6
lines changed

flake.nix

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
gdk = pkgs.google-cloud-sdk.withExtraComponents ([pkgs.google-cloud-sdk.components.gke-gcloud-auth-plugin]);
2424

2525
# The minimal set of packages to build Coder.
26-
devShellPackages = with pkgs; buildPackages ++ [
26+
devShellPackages = with pkgs; [
2727
# google-chrome is not available on OSX
2828
(if pkgs.stdenv.hostPlatform.isDarwin then null else google-chrome)
2929
# strace is not available on OSX
@@ -124,14 +124,17 @@
124124
};
125125
in
126126
{
127-
defaultPackage = formatter; # or replace it with your desired default package.
128127
devShell = pkgs.mkShell {
129128
shellHook = ''
130129
export PLAYWRIGHT_BROWSERS_PATH=${pkgs.playwright-driver.browsers}
131130
export PLAYWRIGHT_SKIP_VALIDATE_HOST_REQUIREMENTS=true
132131
'';
133132
};
134133
packages = {
134+
all = pkgs.buildEnv {
135+
name = "all-packages";
136+
paths = devShellPackages;
137+
};
135138
site = buildSite;
136139

137140
# Copying `OS_ARCHES` from the Makefile.

scripts/lib.sh

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,8 @@ SCRIPT="${BASH_SOURCE[1]:-${BASH_SOURCE[0]}}"
4343
SCRIPT_DIR="$(realpath "$(dirname "$SCRIPT")")"
4444

4545
function project_root {
46-
# If NIX_BUILD_TOP is set, we are in a Nix build and the project root is the
47-
# top of the build directory.
48-
[[ -n "${NIX_BUILD_TOP:-}" ]] && echo "$src" && return
46+
# Nix sets $src in derivations!
47+
[[ -n "${src:-}" ]] && echo "$src" && return
4948

5049
# Try to use `git rev-parse --show-toplevel` to find the project root.
5150
# If this directory is not a git repository, this command will fail.

scripts/update-flake.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ cd "$(dirname "${BASH_SOURCE[0]}")/.."
77

88
OUT=$(mktemp -d -t nar-hash-XXXXXX)
99

10-
echo "Downloading Go modules..."
10+
echo "Downloading Go modules..."
1111
GOPATH="$OUT" go mod download
1212
echo "Calculating SRI hash..."
1313
HASH=$(go run tailscale.com/cmd/nardump --sri "$OUT/pkg/mod/cache/download")

0 commit comments

Comments
 (0)