I've a command in the ~/.local/bin/ path (lets call it dog). Calling the command with the full path ~/.local/bin/dog works as expected .
When I do which dog I get the expected ~/.local/bin/dog. When I check the $PATH ~/.local/bin is there as it should (actually it is /home/ec2-user/.local/bin)
But if simply type dog I get the following error:
-bash: /usr/local/bin/dog: No such file or directory
The output for type dog is dog is hashed (/usr/local/bin/dog)
But for type -a dog is dog is /home/ec2-user/.local/bin/dog
Ideas?