[!exec:gpg] skip 'gpg not found in $PATH'
[githubactionsonwindows] skip 'gpg is broken in GitHub Actions on Windows'

mkhomedir
mkgpgconfig

# test that chezmoi apply --ignore-encrypted does not apply encrypted files
cp golden/.encrypted $HOME
chezmoi add --encrypt ${HOME}${/}.encrypted
rm $HOME/.encrypted
cp $CHEZMOICONFIGDIR/chezmoi.toml golden/chezmoi.toml
rm $CHEZMOICONFIGDIR/chezmoi.toml
chezmoi apply --force --ignore-encrypted
! exists $HOME/.encrypted

# test that chezmoi apply applies the encrypted file
cp golden/chezmoi.toml $CHEZMOICONFIGDIR/chezmoi.toml
chezmoi apply --force
cmp golden/.encrypted $HOME/.encrypted

-- golden/.encrypted --
plaintext
