Git Bash Problem in Installing SQLite

Yea, so the best thing to do when following installation steps is to try to understand roughly what each is doing. This can be annoying, since most of the time you’re just trying to install the thing, but it’ll help you learn better over time. In these days you even have chat gpt, you can ask it what your error messages mean.

(Also careful about sharing your name in public posts).

bash: /c/Users//.bashrc: line 4: unexpected EOF while looking for matching `"’

When you run source ~/.bashrc, source is a command and ~/.bashrc is the target of that command.
It’s important to define this because then we can ask the question: what does the command do?

The documentation for source yields

Read and execute commands from the filename argument in the current shell context. If filename does not contain a slash, the PATH variable is used to find filename, but filename does not need to be executable.

Ok so it reads and executes commands from the file you provide. So if you get an error back, that means there was a command in your target that wasn’t executed (so it’s very logical that sqlite3 will not be found, if that was the change you made to the bashrc file).

~/.bashrc is a special file in the bash shell that executes every time you open a bash shell. So it’s natural that you get the same error back without fixing (so far we covered all our bases for errors).

Now for the error proper unexpected EOF while looking for matching `"’

  • EOF stands for end-of-file
  • The symbol it highlights is a " (depending on how you formatted this might be off).
  • Some command in your ~/.bashrc must therefore have started one " without a second " to match it by the end of the file (there’s a typo somewhere).

You should post your ~/.bashrc if you want feedback on what that may be, but you may be able to find it by yourself.

Link to the quoted documentation (note source is another name for the command . : Bash Reference Manual

2 Likes