Skip to content

Commit 214a4f3

Browse files
committed
Set default value of github_access_token to the automatically generated GitHub token
1 parent c700904 commit 214a4f3

File tree

2 files changed

+2
-7
lines changed

2 files changed

+2
-7
lines changed

action.yml

+2-4
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,9 @@ inputs:
2626
you define are supported by the Nix version you're using.
2727
2828
github_access_token:
29-
required: false
29+
default: ${{ github.token }}
3030
description: |
31-
Configure Nix to use the specified token when fetching from GitHub. If
32-
this setting is not specified, nix-quick-install-action will use the
33-
content of the GITHUB_TOKEN environment variable instead (if set).
31+
Configure Nix to use the specified token when fetching from GitHub.
3432
3533
nix_on_tmpfs:
3634
required: true

nix-quick-install.sh

-3
Original file line numberDiff line numberDiff line change
@@ -71,9 +71,6 @@ fi
7171
if [[ -n "${GITHUB_ACCESS_TOKEN:-}" ]]; then
7272
echo >>"$NIX_CONF_FILE" \
7373
"access-tokens = github.com=$GITHUB_ACCESS_TOKEN"
74-
elif [[ -n "${GITHUB_TOKEN:-}" ]]; then
75-
echo >>"$NIX_CONF_FILE" \
76-
"access-tokens = github.com=$GITHUB_TOKEN"
7774
fi
7875

7976
# Populate the nix db

0 commit comments

Comments
 (0)