configs  Check-in [4cecd9d228]

Overview
Comment:setup.sh: Improve checking for gpg key
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 4cecd9d22810d1ab3727422961ce266fe284ca8e9478a075c08a72eb87e56a3a
User & Date: js 2021-10-28 18:05:06
Context
2021-10-30
13:03
zshrc: Derive MAKEFLAGS if we have nproc check-in: 4ff1f99931 user: js tags: trunk
2021-10-28
18:05
setup.sh: Improve checking for gpg key check-in: 4cecd9d228 user: js tags: trunk
2021-09-23
22:19
zshrc: Add power_now function check-in: bcaeba8978 user: js tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to setup.sh.

30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
	elif have gpg; then
		gpg="gpg"
	else
		gpg=":"
	fi

	gpg_key="7395312F"
	if test $($gpg -a --export $gpg_key 2>/dev/null | wc -c) -gt 0; then
		fossil set --global pgp-command \
			"$gpg -u $gpg_key --clearsign -o"
		fossil set --global clearsign 1
	else
		fossil unset --global pgp-command
		fossil unset --global clearsign
	fi







|







30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
	elif have gpg; then
		gpg="gpg"
	else
		gpg=":"
	fi

	gpg_key="7395312F"
	if $gpg --list-secret-keys $gpg_key &>/dev/null; then
		fossil set --global pgp-command \
			"$gpg -u $gpg_key --clearsign -o"
		fossil set --global clearsign 1
	else
		fossil unset --global pgp-command
		fossil unset --global clearsign
	fi