kaiiiz / hugo-theme-monochrome

Monochrome is a fast, clean and responsive hugo theme
https://kaiiiz.github.io/hugo-theme-monochrome/
MIT License
171 stars 52 forks source link

Running a build generates themes/hugo-theme-monochrome/assets/jsconfig.json #16

Closed Nightfirecat closed 2 years ago

Nightfirecat commented 2 years ago

As the title mentions, running a build generates this file, which causes a diff in the submodule. Ideally, this should be added to .gitignore ala /assets/jsconfig.json line to prevent the theme's submodule from becoming dirty after any build. Presently, this requires a call to git submodule foreach git clean -fd or similar to remove the generated file.

kaiiiz commented 2 years ago

I also have this file, but it's located in the project root folder /assets/jsconfig.json instead of /theme/hugo-theme-monochrome/assets/jsconfig.json.

Based on the document

Hugo will, by default, generate a assets/jsconfig.json file that maps the imports. This is useful for navigation/intellisense help inside code editors, but if you don’t need/want it, you can turn it off.

jsconfig.json is useful for navigation/intellisense help inside code editors. I think it's safe to ignore it from git even if the location of the generated file may vary between users. I'll merge it to the dev branch, and it will be available in the next release.