mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-17 21:01:26 +02:00
Merge commit '3c0036805d64fdd8290f1c4a31371780ff3ea365'
This commit is contained in:
@@ -42,4 +42,31 @@ AWS Amplify is a combination of client library, CLI toolchain, and a Console for
|
||||
|
||||
1. Review your changes and then choose **Save and deploy**. The Amplify Console will pull code from your repository, build changes to the backend and frontend, and deploy your build artifacts at `https://master.unique-id.amplifyapp.com`. Bonus: Screenshots of your app on different devices to find layout issues.
|
||||
|
||||
## Using a Newer Version of Hugo
|
||||
|
||||
If you need to use a different, perhaps newer, version of Hugo than the version currently supported by AWS Amplify, you can modify your build commands to include the downloading of Hugo itself. Here's an example of a build definition that includes the downloading of Hugo. Note that in ths example the "extended" version of Hugo is being used which includes support for SASS/SCSS.
|
||||
|
||||
```
|
||||
version: 0.1
|
||||
frontend:
|
||||
phases:
|
||||
# IMPORTANT - Please verify your build commands
|
||||
build:
|
||||
commands:
|
||||
- wget https://github.com/gohugoio/hugo/releases/download/v0.62.2/hugo_extended_0.62.2_Linux-64bit.tar.gz
|
||||
- tar -xf hugo_extended_0.62.2_Linux-64bit.tar.gz
|
||||
- mv hugo /usr/bin/hugo
|
||||
- rm -rf hugo_extended_0.62.2_Linux-64bit.tar.gz
|
||||
- hugo version
|
||||
- hugo
|
||||
artifacts:
|
||||
# IMPORTANT - Please verify your build output directory
|
||||
baseDirectory: public
|
||||
files:
|
||||
- '**/*'
|
||||
cache:
|
||||
paths: []
|
||||
|
||||
```
|
||||
|
||||
[Quick Start]: /getting-started/quick-start/
|
||||
|
@@ -58,7 +58,7 @@ This is a much simpler setup as your Hugo files and generated content are publis
|
||||
5. Once you are happy with the results:
|
||||
* Press <kbd>Ctrl</kbd>+<kbd>C</kbd> to kill the server
|
||||
* Before proceeding run `rm -rf public` to completely remove the `public` directory
|
||||
6. `git submodule add -b master git@github.com:<USERNAME>/<USERNAME>.github.io.git public`. This creates a git [submodule][]. Now when you run the `hugo` command to build your site to `public`, the created `public` directory will have a different remote origin (i.e. hosted GitHub repository).
|
||||
6. `git submodule add -b master https://github.com/<USERNAME>/<USERNAME>.github.io.git public`. This creates a git [submodule][]. Now when you run the `hugo` command to build your site to `public`, the created `public` directory will have a different remote origin (i.e. hosted GitHub repository).
|
||||
|
||||
### Put it Into a Script
|
||||
|
||||
|
Reference in New Issue
Block a user