mirror of
				https://github.com/gohugoio/hugo.git
				synced 2024-05-11 05:54:58 +00:00 
			
		
		
		
	docs: Fix PATH issue in the instruction for Windows 10
i.e., "The PATH entry should be the folder where Hugo lives, not the binary." Fixes #2280. Also fix a rendering issue with list entries that consist of multiple paragraphs by using four spaces instead of two. Special thanks to @shurcooL for the insight! (Fixes #2285) Also made a few minor formatting tweaks.
This commit is contained in:
		| @@ -36,7 +36,7 @@ You'll need a place to store the Hugo executable, your content (the files that y | |||||||
|  |  | ||||||
| 1. Download the latest zipped Hugo executable from the [Hugo Releases](https://github.com/spf13/hugo/releases) page. | 1. Download the latest zipped Hugo executable from the [Hugo Releases](https://github.com/spf13/hugo/releases) page. | ||||||
| 2. Extract all contents to your `..\Hugo\bin` folder. | 2. Extract all contents to your `..\Hugo\bin` folder. | ||||||
| 3. In Powershell or your preferred CLI, add the `hugo.exe` executable to your PATH by navigating to `C:\Hugo\bin` (or the location of your hugo.exe file) and use the command `set PATH=%PATH%;C:\Hugo\bin`. If the `hugo` command does not work after a reboot, you may have to run the command prompt as administrator. | 3. In PowerShell or your preferred CLI, add the `hugo.exe` executable to your PATH by navigating to `C:\Hugo\bin` (or the location of your hugo.exe file) and use the command `set PATH=%PATH%;C:\Hugo\bin`. If the `hugo` command does not work after a reboot, you may have to run the command prompt as administrator. | ||||||
|  |  | ||||||
| ## Less technical users | ## Less technical users | ||||||
|  |  | ||||||
| @@ -48,31 +48,38 @@ You'll need a place to store the Hugo executable, your content (the files that y | |||||||
| 6. You should now have three new files: hugo.exe, license.md, and readme.md. (you can delete the ZIP download now.) | 6. You should now have three new files: hugo.exe, license.md, and readme.md. (you can delete the ZIP download now.) | ||||||
| 7. Now add Hugo to your Windows PATH settings: | 7. Now add Hugo to your Windows PATH settings: | ||||||
|  |  | ||||||
|   #### For Windows 10 users: |     ### For Windows 10 users: | ||||||
|   - Right click on the **Start** button |  | ||||||
|   - Click on **System** |     - Right click on the **Start** button. | ||||||
|   - Click on **Advanced System Settings** on the left |     - Click on **System**. | ||||||
|   - Click on the **Environment Variables** button on the bottom |     - Click on **Advanced System Settings** on the left. | ||||||
|   - In the User variables section, find the row that starts with PATH (PATH will be all caps) |     - Click on the **Environment Variables...** button on the bottom. | ||||||
|   - Double-click on **PATH** |     - In the User variables section, find the row that starts with PATH (PATH will be all caps). | ||||||
|   - Click the **New** button. |     - Double-click on **PATH**. | ||||||
|   - Type in Hugo's path, which is `C:\Hugo\bin\hugo.exe` if you went by the instructions above. Press Enter when you're done typing. |     - Click the **New...** button. | ||||||
|  |     - Type in the folder where `hugo.exe` was extracted, which is `C:\Hugo\bin` if you went by the instructions above. *The PATH entry should be the folder where Hugo lives, not the binary.* Press <kbd>Enter</kbd> when you're done typing. | ||||||
|     - Click OK at every window to exit. |     - Click OK at every window to exit. | ||||||
|  |  | ||||||
|     (Note that the path editor in Windows 10 was added in the large [November 2015 Update](https://blogs.windows.com/windowsexperience/2015/11/12/first-major-update-for-windows-10-available-today/). You'll need to have that or a later update installed for the above steps to work. You can see what Windows 10 build you have by clicking on the Start button → Settings → System → About. See [here](http://www.howtogeek.com/236195/how-to-find-out-which-build-and-version-of-windows-10-you-have/) for more.) |     > <small>Note that the path editor in Windows 10 was added in the large [November 2015 Update](https://blogs.windows.com/windowsexperience/2015/11/12/first-major-update-for-windows-10-available-today/). You'll need to have that or a later update installed for the above steps to work. You can see what Windows 10 build you have by clicking on the <i class="fa fa-windows"></i> Start button → Settings → System → About. See [here](http://www.howtogeek.com/236195/how-to-find-out-which-build-and-version-of-windows-10-you-have/) for more.)</small> | ||||||
|  |  | ||||||
|  |     ### For Windows 7 and 8.x users: | ||||||
|  |  | ||||||
|   #### For Windows 7 and 8.x users |  | ||||||
|     Windows 7 and 8.1 do not include the easy path editor included in Windows 10, so non-technical users on those platforms are advised to install a free third-party path editor like [Windows Environment Variables Editor](http://eveditor.com/) or [Path Editor](https://patheditor2.codeplex.com/). |     Windows 7 and 8.1 do not include the easy path editor included in Windows 10, so non-technical users on those platforms are advised to install a free third-party path editor like [Windows Environment Variables Editor](http://eveditor.com/) or [Path Editor](https://patheditor2.codeplex.com/). | ||||||
|  |  | ||||||
| ## Verify the executable | ## Verify the executable | ||||||
|  |  | ||||||
| Run a few commands to verify that the executable is ready to run and then build a sample site to get started. | Run a few commands to verify that the executable is ready to run, and then build a sample site to get started. | ||||||
|  |  | ||||||
| 1. Open a command prompt window. | 1. Open a command prompt window. | ||||||
|  |  | ||||||
| 2. At the prompt, type `hugo help` and press the Enter key. You should see output that starts with: | 2. At the prompt, type `hugo help` and press the <kbd>Enter</kbd> key. You should see output that starts with: | ||||||
|  |  | ||||||
|     {{< nohighlight >}}A Fast and Flexible Static Site Generator built with love by spf13 and friends in Go. Complete documentation is available at http://gohugo.io |     {{< nohighlight >}}hugo is the main command, used to build your Hugo site. | ||||||
|  |  | ||||||
|  | Hugo is a Fast and Flexible Static Site Generator | ||||||
|  | built with love by spf13 and friends in Go. | ||||||
|  |  | ||||||
|  | Complete documentation is available at http://gohugo.io/. | ||||||
| {{< /nohighlight >}} | {{< /nohighlight >}} | ||||||
|  |  | ||||||
|     If you do, then the installation is complete. If you don't, double-check the path that you placed the `hugo.exe` file in and that you typed that path correctly when you added it to your PATH variable. If you're still not getting the output, post a note on the Hugo discussion list (in the `Support` topic) with your command and the output. |     If you do, then the installation is complete. If you don't, double-check the path that you placed the `hugo.exe` file in and that you typed that path correctly when you added it to your PATH variable. If you're still not getting the output, post a note on the Hugo discussion list (in the `Support` topic) with your command and the output. | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user