diff --git a/pkgs/development/tools/parsing/tree-sitter/update.nix b/pkgs/development/tools/parsing/tree-sitter/update.nix index 3bce9868912b..815a1dcbb064 100644 --- a/pkgs/development/tools/parsing/tree-sitter/update.nix +++ b/pkgs/development/tools/parsing/tree-sitter/update.nix @@ -366,7 +366,7 @@ let set -euo pipefail args=( '--silent' ) - if [ -n "$GITHUB_TOKEN" ]; then + if [ -n "''${GITHUB_TOKEN:-}" ]; then args+=( "-H" "Authorization: token ''${GITHUB_TOKEN}" ) fi args+=( "https://api.github.com/repos/${urlEscape orga}/${urlEscape repo}/releases/latest" ) @@ -390,7 +390,7 @@ let set -euo pipefail args=( '--silent' ) - if [ -n "$GITHUB_TOKEN" ]; then + if [ -n "''${GITHUB_TOKEN:-}" ]; then args+=( "-H" "Authorization: token ''${GITHUB_TOKEN}" ) fi args+=( 'https://api.github.com/orgs/${urlEscape orga}/repos?per_page=100' )