1

I was trying to set up launching Sublime from the command line and I might make some mistakes. Now I can open my sublime_text.exe on Git Bash by inputting "subl" , which is what I want, but it shows stuff like this because of my mistakes:

enter image description here

And I know it is because something is wrong with bashrc. When I test bashrc it shows these 3 lines as well:

enter image description here

I do not want those stuff and how can I fix it?

jww
  • 97,681
  • 90
  • 411
  • 885
Daniel
  • 11
  • 3
  • Can you include the contents of your `bashrc`? – Harald Nordgren Feb 05 '17 at 01:11
  • I just used image urls on those blue words. Please click them 2 and see my screenshots. Thanks. XP – Daniel Feb 05 '17 at 01:46
  • I saw you screenshots, those are the outputs. But to be able to help you we need to know the contents of bashrc. I suspect there is something wrong there related to `var` and `begin`. – Harald Nordgren Feb 05 '17 at 01:49
  • Oh I fixed that just now. I found ".bashrc" and deleted some stuff that I did not need and those lines were finally gone. Actually, I wrote those words like var and begin into it by accident. Thanks anyway. – Daniel Feb 05 '17 at 02:05
  • It would be nice if you post an answer, showing what modifications you did to your bashrc. Otherwise, this question has no reason to stay on this site. – linuxfan says Reinstate Monica Feb 05 '17 at 07:54

1 Answers1

0

Regarding your subl alias, make sure to use unix-like path:

alias subl="/c/Program\ Files/Sublime\ Text\ 3/sublime_text.exe"

Or (simpler)

export PATH="$PATH:/c/Program Files/Sublime Text 3"
alias subl=sublime_text.exe
Community
  • 1
  • 1
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250