pfetch: Added PF_SOURCE. Closes #34
This commit is contained in:
parent
0dcc4d6a82
commit
a7b0439aeb
|
@ -57,6 +57,11 @@ PF_INFO="ascii"
|
||||||
# Example: Only Information.
|
# Example: Only Information.
|
||||||
PF_INFO="title os host kernel uptime pkgs memory"
|
PF_INFO="title os host kernel uptime pkgs memory"
|
||||||
|
|
||||||
|
# A file to source before running pfetch.
|
||||||
|
# Default: unset
|
||||||
|
# Valid: A shell script
|
||||||
|
PF_SOURCE=""
|
||||||
|
|
||||||
# Separator between info name and info data.
|
# Separator between info name and info data.
|
||||||
# Default: unset
|
# Default: unset
|
||||||
# Valid: string
|
# Valid: string
|
||||||
|
|
5
pfetch
5
pfetch
|
@ -1296,6 +1296,11 @@ main() {
|
||||||
# This gives full control over what it displayed on the screen.
|
# This gives full control over what it displayed on the screen.
|
||||||
exec 6>&1 >/dev/null
|
exec 6>&1 >/dev/null
|
||||||
|
|
||||||
|
# Allow the user to execute their own script and modify or
|
||||||
|
# extend pfetch's behavior.
|
||||||
|
# shellcheck source=/dev/null
|
||||||
|
. "${PF_SOURCE:-/dev/null}" ||:
|
||||||
|
|
||||||
# Ensure that the 'TMPDIR' is writable as heredocs use it and
|
# Ensure that the 'TMPDIR' is writable as heredocs use it and
|
||||||
# fail without the write permission. This was found to be the
|
# fail without the write permission. This was found to be the
|
||||||
# case on Android where the temporary directory requires root.
|
# case on Android where the temporary directory requires root.
|
||||||
|
|
Loading…
Reference in New Issue
Block a user