Skip to main content
1 of 4
Alexander Mills
  • 10.9k
  • 27
  • 120
  • 214

Why is sh (not bash) sourcing my bashrc / bash_profile files?

I am getting this one when I open a terminal session:

sh: error importing function definition for `read.json'

sh: error importing function definition for `ts-project'

sh doesn't like these functions because they look like:

read.json(){
   ::
}

and

ts-project(){
   ::
{

the real question is - why is sh touching/interpreting these files? I am on MacOS and seen this before, it's such a mystery. I would think only bash would be loading these files.

Alexander Mills
  • 10.9k
  • 27
  • 120
  • 214