mirror of
https://github.com/DeterminateSystems/nix-installer-action.git
synced 2025-01-11 06:42:19 +01:00
Whoops did not save
This commit is contained in:
parent
e7cc0afd1d
commit
56ecdbd741
1 changed files with 5 additions and 5 deletions
10
action.yml
10
action.yml
|
@ -159,19 +159,19 @@ runs:
|
||||||
echo "Set NIX_INSTALLER_NIX_PACKAGE_URL=$NIX_INSTALLER_NIX_PACKAGE_URL"
|
echo "Set NIX_INSTALLER_NIX_PACKAGE_URL=$NIX_INSTALLER_NIX_PACKAGE_URL"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
NIX_EXTRA_CONF_FILE=/tmp/tmp.jvU0yFBwoanix-installer-extra-conf
|
NIX_EXTRA_CONF_FILE=$(mktemp --suffix=nix-installer-extra-conf)
|
||||||
|
|
||||||
if [ -n "${{ inputs.extra-conf }}" ]; then
|
if [ -n "${{ inputs.extra-conf }}" ]; then
|
||||||
echo "${{ inputs.extra-conf }}" | tee -a ${NIX_EXTRA_CONF_FILE}
|
echo "${{ inputs.extra-conf }}" >> ${NIX_EXTRA_CONF_FILE}
|
||||||
fi
|
fi
|
||||||
if [ -n "${{ inputs.github-token }}" ]; then
|
if [ -n "${{ inputs.github-token }}" ]; then
|
||||||
echo "access-tokens = github.com=${{ inputs.github-token }}" | tee -a ${NIX_EXTRA_CONF_FILE}
|
echo "access-tokens = github.com=${{ inputs.github-token }}" >> ${NIX_EXTRA_CONF_FILE}
|
||||||
fi
|
fi
|
||||||
if [ "${{ inputs.trust-runner-user }}" == "true" ]; then
|
if [ "${{ inputs.trust-runner-user }}" == "true" ]; then
|
||||||
echo "trusted-users = root $USER" | tee -a ${NIX_EXTRA_CONF_FILE}
|
echo "trusted-users = root $USER" >> ${NIX_EXTRA_CONF_FILE}
|
||||||
fi
|
fi
|
||||||
if [ -n "$NIX_EXTRA_CONF" ]; then
|
if [ -n "$NIX_EXTRA_CONF" ]; then
|
||||||
export NIX_INSTALLER_EXTRA_CONF="$(cat NIX_EXTRA_CONF_FILE")"
|
export NIX_INSTALLER_EXTRA_CONF="$(cat ${NIX_EXTRA_CONF_FILE}")"
|
||||||
echo "Set NIX_INSTALLER_EXTRA_CONF=$NIX_INSTALLER_EXTRA_CONF"
|
echo "Set NIX_INSTALLER_EXTRA_CONF=$NIX_INSTALLER_EXTRA_CONF"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue