-
Notifications
You must be signed in to change notification settings - Fork 4
Hot to get started with tacademia
(1) First, make sure you have Hugo installed: https://gohugo.io/getting-started/installing/
(2) After that, you should create a new Hugo site. To do that, locally on your machine open a terminal and type the following command
hugo new site name-of-project
If this command is successful you should see something like the following:
Congratulations! Your new Hugo site is created in /Users/francopestilli/git/tacademia-tests/name-of-project.
Just a few more steps and you're ready to go:
A. Download a theme into the same-named folder.
Choose a theme from https://themes.gohugo.io/ or create your own with the "hugo new theme <THEMENAME>" command.
B. Perhaps you want to add some content. You can add single files with "hugo new <SECTIONNAME>/<FILENAME>.<FORMAT>".
C. Start the built-in live server via "hugo server".
Visit https://gohugo.io/ for quickstart guide and full documentation.
(base) francos-mbp:tacademia-tests francopestilli$
After, this you will need to move inside the new project folder: cd name-of-project
(3) After creating a new Hugo site, we can add the tacademia theme to your site so that you can start editing the site.
To do this, type the following commands in a terminal:
cd themes
git clone https://github.com/PESTILLILAB/tacademia.hugo.git
(4) Copy the tacademia config.toml file from the tacademia folder to the root folder of your Hugo project.
mv ../config.toml ../config.toml-orig
mv tacademia/sample_config.toml ../config.toml
After that, move to the root of your Hugo site project (it will simplify some of the upcoming commands): cd ../
(5) tacademia comes with an example site. The content of the example site can be found inside tacademia/exampleSite/content. Next, we will suggest starting from that example site and edit that site as a start.
To do so, copy the content of the example site to the content of your root Hugo site:
cp -vR themes/tacademia.hugo/exampleSite/content/* content/
We will also want to copy another file that will allow the Hugo site to render:
cp -v themes/tacademia.hugo/layouts/index.html layouts/
(6) View the current version of your site locally on your Machine.
To do so we will use the Hugo serve command: hugo serve
This command will open a local webserver to render your new site locally on your machine.
(7) If the above all worked well, you should now have an URL for a local host where your new site is rendered.
(8) Next we will want to deploy the newly created site using GitHub. Here is a tutorial about how to do that: