Skip to content

Commit

Permalink
Upgrade Hugo version, Upgrade outdated/deprecated packages and Implem…
Browse files Browse the repository at this point in the history
…ent premium themes file structures
  • Loading branch information
tfsazib committed Dec 17, 2024
1 parent bec36f7 commit 64db97d
Show file tree
Hide file tree
Showing 125 changed files with 15,607 additions and 7,541 deletions.
14 changes: 14 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
; https://editorconfig.org

root = true

[*]
charset = utf-8
end_of_line = lf
indent_size = 2
indent_style = space
trim_trailing_whitespace = true
insert_final_newline = true

[*.md]
trim_trailing_whitespace = false
13 changes: 0 additions & 13 deletions .forestry/front_matter/templates/new-page.yml

This file was deleted.

20 changes: 0 additions & 20 deletions .forestry/front_matter/templates/post.yml

This file was deleted.

106 changes: 0 additions & 106 deletions .forestry/settings.yml

This file was deleted.

75 changes: 75 additions & 0 deletions .github/workflows/hugo.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
# Sample workflow for building and deploying a Hugo site to GitHub Pages
name: Deploy Hugo site to Pages

on:
# Runs on pushes targeting the default branch
push:
branches: ["main"]

# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write

# Environment variables available to all jobs and steps in this workflow
env:
HUGO_ENV: production
HUGO_VERSION: "0.124.1"
GO_VERSION: "1.20.5"
NODE_VERSION: "18.15.0"
TINA_CLIENT_ID: ${{ vars.TINA_CLIENT_ID }}
TINA_TOKEN: ${{ vars.TINA_TOKEN }}

jobs:
# Build job
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: ${{ env.NODE_VERSION }}

- name: Install Hugo
run: |
curl -LO "https://github.com/gohugoio/hugo/releases/download/v${{ env.HUGO_VERSION }}/hugo_extended_${{ env.HUGO_VERSION }}_Linux-64bit.tar.gz"
tar -xvf hugo_extended_${{ env.HUGO_VERSION }}_Linux-64bit.tar.gz
sudo mv hugo /usr/local/bin/
rm hugo_extended_${{ env.HUGO_VERSION }}_Linux-64bit.tar.gz
hugo version
- name: Install Go
run: |
curl -LO "https://dl.google.com/go/go${{ env.GO_VERSION }}.linux-amd64.tar.gz"
sudo tar -C /usr/local -xzf go${{ env.GO_VERSION }}.linux-amd64.tar.gz
echo "export PATH=$PATH:/usr/local/go/bin" >> $GITHUB_ENV
rm go${{ env.GO_VERSION }}.linux-amd64.tar.gz
go version
- name: Setup Project
run: npm run project-setup

- name: Install npm dependencies
run: npm install

- name: Publish to GitHub Pages
run: npm run build

- name: Upload artifact
uses: actions/upload-pages-artifact@v1
with:
path: ./public

# Deployment job
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2
9 changes: 8 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,11 @@ node_modules
builds
package-lock.json
public
resources
resources
.hugo_build.lock
jsconfig.json
hugo_stats.json
go.sum
yarn.lock
.lock
jsconfig.json
39 changes: 39 additions & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
stages:
- build

variables:
HUGO_ENV: production
HUGO_VERSION: "0.124.1"
GO_VERSION: "1.20.5"
NODE_VERSION: "18.16.1"

cache:
paths:
- node_modules/

default:
image: node:${NODE_VERSION}
before_script:
- echo "USING NODE ${NODE_VERSION}"
- apt-get update && apt-get install -y curl
- curl -LO "https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_Linux-64bit.tar.gz"
- tar -xvf hugo_extended_${HUGO_VERSION}_Linux-64bit.tar.gz
- mv hugo /usr/local/bin/
- rm hugo_extended_${HUGO_VERSION}_Linux-64bit.tar.gz
- echo "HUGO ${HUGO_VERSION} INSTALLED"
- curl -LO "https://dl.google.com/go/go${GO_VERSION}.linux-amd64.tar.gz"
- tar -C /usr/local -xzf go${GO_VERSION}.linux-amd64.tar.gz
- export PATH=$PATH:/usr/local/go/bin
- rm go${GO_VERSION}.linux-amd64.tar.gz
- echo "GO ${GO_VERSION} INSTALLED"
- npm install

pages:
stage: build
script:
- npm run project-setup
- npm run build
- echo "SITE BUILT SUCCESSFULLY! LIVE AT https://$GITLAB_USER_LOGIN.gitlab.io/$CI_PROJECT_NAME/"
artifacts:
paths:
- public
3 changes: 3 additions & 0 deletions .jshintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"esversion": 8
}
12 changes: 12 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"overrides": [
{
"files": ["*.html"],
"options": {
"parser": "go-template",
"bracketSameLine": true,
"htmlWhitespaceSensitivity": "ignore"
}
}
]
}
6 changes: 6 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"recommendations": [
"budparr.language-hugo-vscode",
"tamasfe.even-better-toml"
]
}
20 changes: 0 additions & 20 deletions LICENSE

This file was deleted.

6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,11 @@ Get It Now | [![download-light](https://demo.gethugothemes.com/icons/download.pn
# clone the repository
git clone [email protected]:themefisher/bigspring-light.git

# cd in the project directory
$ cd bigspring-light/exampleSite/
# Install Dependencies
npm install

# Start local dev server
$ hugo server --themesDir ../..
$ npm run dev:example
```

Or Check out [Full Documentation](https://docs.gethugothemes.com/bigspring/?ref=github).
Expand Down
5 changes: 3 additions & 2 deletions archetypes/default.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@
title: "{{ replace .Name "-" " " | title }}"
date: {{ .Date }}
draft: true
---

# description
description: "This is meta description"
---
33 changes: 33 additions & 0 deletions assets/js/bootstrap.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
// bootstrap js components
// import Alert from "js/bootstrap/src/alert";
// import Button from "js/bootstrap/src/button";
// import Carousel from "js/bootstrap/src/carousel";
import Collapse from "js/bootstrap/src/collapse";
import Dropdown from "js/bootstrap/src/dropdown";
import Modal from "js/bootstrap/src/modal";
// import Offcanvas from "js/bootstrap/src/offcanvas";
// import Popover from "js/bootstrap/src/popover";
// import ScrollSpy from "js/bootstrap/src/scrollspy";
import Tab from "js/bootstrap/src/tab";
// import Toast from "js/bootstrap/src/toast";
// import Tooltip from "js/bootstrap/src/tooltip";

// bootstrap popover and toats
// (function () {
// "use strict";
// let toastElList = [].slice.call(document.querySelectorAll(".toast"));
// let toastList = toastElList.map(function (toastEl) {
// return new Toast(toastEl);
// });

// toastList.forEach(function (toast) {
// toast.show();
// });

// let popoverTriggerList = [].slice.call(
// document.querySelectorAll('[data-bs-toggle="popover"]')
// );
// popoverTriggerList.map(function (popoverTriggerEl) {
// return new Popover(popoverTriggerEl);
// });
// })();
Loading

0 comments on commit 64db97d

Please sign in to comment.