1--- 2title: Installation 3weight: 15 4--- 5 6The following steps are here to help you initialize your new website. If you don't know Hugo at all, we strongly suggest you to train by following this [great documentation for beginners](https://gohugo.io/overview/quickstart/). 7 8## Create your project 9 10Hugo provides a `new` command to create a new website. 11 12``` 13hugo new site <new_project> 14``` 15 16## Install the theme 17 18Install the **Hugo-theme-learn** theme by following [this documentation](https://gohugo.io/themes/installing/) 19 20The theme's repository is: https://github.com/matcornic/hugo-theme-learn.git 21 22Alternatively, you can [download the theme as .zip](https://github.com/matcornic/hugo-theme-learn/archive/master.zip) file and extract it in the themes directory 23 24## Basic configuration 25 26When building the website, you can set a theme by using `--theme` option. We suggest you to edit your configuration file and set the theme by default. By the way, add requirements for search functionnality to be enabled. 27 28```toml 29# Change the default theme to be use when building the site with Hugo 30theme = "hugo-theme-learn" 31 32# For search functionnality 33[outputs] 34home = [ "HTML", "RSS", "JSON"] 35``` 36 37## Create your first chapter page 38 39Chapters are pages containing other child pages. It has a special layout style and usually just contains a _chapter name_, the _title_ and a _brief abstract_ of the section. 40 41``` 42### Chapter 1 43 44# Basics 45 46Discover what this Hugo theme is all about and the core-concepts behind it. 47``` 48 49renders as 50 51![A Chapter](/basics/installation/images/chapter.png?classes=shadow&width=60%) 52 53**Hugo-theme-learn** provides archetypes to create skeletons for your website. Begin by creating your first chapter page with the following command 54 55``` 56hugo new --kind chapter basics/_index.md 57``` 58 59By opening the given file, you should see the property `chapter=true` on top, meaning this page is a _chapter_. 60 61## Create your first content pages 62 63Then, create content pages inside the previous chapter. Here are two ways to create content in the chapter : 64 65``` 66hugo new basics/first-content.md 67hugo new basics/second-content/_index.md 68``` 69 70Feel free to edit thoses files by adding some sample content and replacing `title` value in the beginning of the files. 71 72## Launching the website locally 73 74Launch the following command: 75 76``` 77hugo serve 78``` 79 80Go to `http://localhost:1313` 81 82You should notice three things: 83 841. You have a left **Basics** menu, containing two submenus with names equals to `title` properties in previously created files. 852. The home page explains you to how to customize it. Follow the instructions. 863. With `hugo serve` command, the page refresh as soon as you save a file. Neat ! 87 88## Build the website 89 90When your site is ready to deploy, launch the following command: 91 92``` 93hugo 94``` 95 96A `public` folder has been generated, containing all statics content and assets for your website. It can now be deployed on any web server ! 97 98{{% notice note %}} 99This website can be automatically published and hosted with [Netlify](https://www.netlify.com/) (Read more about [Automated HUGO deployments with Netlify](https://www.netlify.com/blog/2015/07/30/hosting-hugo-on-netlifyinsanely-fast-deploys/)). Alternatively, you can use [Github pages](https://gohugo.io/hosting-and-deployment/hosting-on-github/) 100{{% /notice %}}