Hi,
I have created a site through Hugo and so far everything works out perfectly. However, when I try to upload my files to GitHub, I get an error because my hugo.exe is too big (162 MB).
Can someone explain how this is possible and how I can fix this?
Cheers,
Brenda
Well, I’m following a tutorial and I copy exactly what they are doing. I know one thing, without this file it defenitely doesn’t work. In that case I only see an empty page with the name of my repository…
Hi Brenda, you generally shouldn’t commit your binaries (or executable) files into GitHub. Github is for source-code.
I don’t know which tutorial you’re following, but if they’re telling you to put Hugo.exe into GitHub, please be aware this is very unusual if not downright ill advised.
The Hugo.exe should live where-ever you downloaded/installed Hugo on your system.
So, for example,
put Hugo in c:\Hugo\Hugo.exe
your source code for your website is somewhere else, maybe c:\git\my-example-site
now, when you’re in your command line in the git\my-example-site\ directory, you can run Hugo like this: c:\Hugo\Hugo.exe --server - notice we’re giving the full-path here
if c:\Hugo\ is in your $PATH environment variable, you can just run Hugo --whateverswitch in your directory WITHOUT having to type the entire path.