This is a basic Git and Hugo flow, arguably there is always the discussion on the use of git pull rather than fetch and merge. However lets keep it straight forward.
- Ensure you are in the correct directory in Terminal within Visual Studio Code
- Run ‘git pull’ to refresh local repository
- Add new content either by adding the file in the Content/Post directory or via Hugo. Images go in the static/img directory (tidy up file names and filesizes). Make sure your filename for the new page ends in .md
- To preview your new page run ‘hugo serve’ this runs the site on localhost
- Once happy run git status to view pending changes
- Either add the changes one by one using ‘git add [filename]’ or ‘git add –all’ (thats 2 dashes before all)
- Commit the changes using ‘git commit -m “some descriptive text”’
- Push the changes to remote git repository using ‘git push’