Skip to main content
1 of 5
temp
  • 744
  • 6
  • 3

"Are there other commands which prints only the shell variables, without the functions?"

In man bash, in section SHELL BUILTIN COMMANDS (in the set section) it says: "In posix mode, only shell variables are listed."

(set -o posix; set)

I know that the question has been answered but (set -o posix; set) is cleaner then most suggestions.

temp
  • 744
  • 6
  • 3