I typed psql and I get this:
psql
psql: could not connect to server: No such file or directory Is the server running locally and accepting con
I had the similar issue and the problem was in the config file pg_hba.conf. I had earlier made some changes which was causing the server to error out while trying to start it. Commenting out the extra additions solved the problem.