blob: ccff574f157cc64846d2c4a911215c447f98fb08 [file] [log] [blame]
Garret Kellycb74aff2019-10-21 14:53:09 -04001#!/bin/bash
2# Copyright lowRISC contributors.
3# Licensed under the Apache License, Version 2.0, see LICENSE for details.
4# SPDX-License-Identifier: Apache-2.0
5
6set -e
7
8TARGET=$1
9
10case "${TARGET}" in
11 "public" | "staging")
12 ;;
13
14 *)
15 echo "You must specify either \"public\" or \"staging\""
16 exit 1
17 ;;
18esac
19
20DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
21cd $DIR
22rm -rf public
23
Garret Kellyac03f712019-11-07 14:32:49 -050024hugo
25hugo deploy --target "${TARGET}" --confirm --verbose --maxDeletes -1 --invalidateCDN