You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

installation.md 2.1KB

5 vuotta sitten
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. ---
  2. title: "How To Setup Meghna Hugo"
  3. date: 2018-09-12T14:51:12+06:00
  4. author: Mark Dinn
  5. image: images/blog/meghna.jpg
  6. description : "This is meta description"
  7. ---
  8. ## Install this template by following those simple steps:
  9. ### STEP-1 : Hugo installation
  10. Check this link below for install hugo on your computer.
  11. [hugo install documentation](https://gohugo.io/getting-started/installing/)
  12. ### STEP-2 : Create your project
  13. Hugo provides a `new` command to create a new website.
  14. ```
  15. hugo new site <new_project>
  16. ```
  17. ### STEP-3 : Install the theme
  18. Run this command
  19. ```
  20. hugo new site meghna-hugo
  21. ```
  22. and then go to the themes folder inside of meghna-hugo folder. You can also use this command ```cd meghna-hugo/themes``` for going to this folder.
  23. Then run the command
  24. ```
  25. git clone git@github.com:themefisher/meghna-hugo.git
  26. ```
  27. Alternatively, you can [download the theme as .zip](https://github.com/themefisher/meghna-hugo/archive/master.zip) file and extract it in the `themes` directory
  28. After that you need to go to the `meghna-hugo/exampleSite` folder and copy or cut all the elements, and now go back to the root folder and paste it here.
  29. open the command prompt again and run `cd ../` command for go back to the root folder.
  30. ### STEP-4 : Host locally
  31. Launching the website locally by using the following command:
  32. ```
  33. hugo serve
  34. ```
  35. Go to `http://localhost:1313`
  36. Or you can check this video documentation for installing this template:
  37. {{< youtube 3O3qvDoVp5g >}}
  38. ### STEP-5 : Basic configuration
  39. When building the website, you can set a theme by using `--theme` option. However, we suggest you modify the configuration file (`config.toml`) and set the theme as the default.
  40. ```toml
  41. # Change the default theme to be use when building the site with Hugo
  42. theme = "meghna-hugo"
  43. ```
  44. ### STEP-6 : Create your first content pages
  45. ```
  46. hugo new blog/post-name.md
  47. ```
  48. ### STEP-7 : Build the website
  49. When your site is ready to deploy, run the following command:
  50. ```
  51. hugo
  52. # You can also create a minified version by using this command:
  53. hugo--minify
  54. ```
  55. A `public` folder will be generated, containing all static content and assets for your website. It can now be deployed on any web server.