-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 03bc32c
Showing
35 changed files
with
1,109 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
name: Deploy Hugo from Obsidian notes | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
workflow_dispatch: | ||
|
||
jobs: | ||
publish_job: | ||
runs-on: ubuntu-latest | ||
name: Publish Obsidian notes to Github pages | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
token: ${{ secrets.DWARVES_PAT }} | ||
|
||
- name: Checkout contents repo | ||
uses: actions/checkout@v4 | ||
with: | ||
token: ${{ secrets.DWARVES_PAT }} | ||
repository: dwarvesf/content | ||
path: vault | ||
|
||
- name: Cache cargo plugins | ||
id: cache-obsidian-export | ||
uses: actions/cache@v1 | ||
with: | ||
path: ~/.cargo/bin/ | ||
key: ${{ runner.os }}-cargo-plugins | ||
|
||
- name: Install obsidian-export | ||
if: steps.cache-obsidian-export.outputs.cache-hit != 'true' | ||
uses: actions-rs/install@v0.1 | ||
with: | ||
crate: obsidian-export | ||
version: latest | ||
|
||
- name: Setup Hugo | ||
uses: peaceiris/actions-hugo@v2 | ||
with: | ||
hugo-version: 'latest' | ||
extended: true | ||
|
||
- name: Create content dir if not exists | ||
shell: bash | ||
run: mkdir -p ./content | ||
|
||
- name: Export Vault | ||
shell: bash | ||
run: obsidian-export ./vault ./content | ||
|
||
- name: Build Hugo | ||
shell: bash | ||
run: hugo --minify | ||
|
||
- name: Deploy | ||
uses: peaceiris/actions-gh-pages@v3 | ||
if: ${{ github.ref == 'refs/heads/main' }} | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
publish_dir: ./public |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# If you prefer the allow list template instead of the deny list, see community template: | ||
# https://github.com/github/gitignore/blob/main/community/Golang/Go.AllowList.gitignore | ||
# | ||
# Binaries for programs and plugins | ||
*.exe | ||
*.exe~ | ||
*.dll | ||
*.so | ||
*.dylib | ||
|
||
# Test binary, built with `go test -c` | ||
*.test | ||
|
||
# Output of the go coverage tool, specifically when used with LiteIDE | ||
*.out | ||
|
||
# Dependency directories (remove the comment below to include it) | ||
# vendor/ | ||
|
||
# Go workspace file | ||
go.work | ||
|
||
# hugo dev-related files | ||
resources | ||
.hugo_build.lock | ||
vault/ | ||
public/* | ||
!public/CNAME | ||
content/ |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
setup: | ||
@brew install rust | ||
@brew install hugo | ||
@cargo install obsidian-export | ||
@if [ ! -d "./vault" ]; then git clone git@github.com:dwarvesf/content.git vault; \ | ||
else pushd vault && git pull && popd; fi | ||
@mkdir -p ./content | ||
|
||
build: | ||
@cd vault && git pull | ||
@obsidian-export ./vault ./content | ||
@hugo --minify | ||
|
||
run: | ||
hugo server | ||
|
||
build-target: | ||
@mkdir -p vault content | ||
@rsync -avh $(path) ./vault/ --delete | ||
@obsidian-export ./vault/ ./content/ | ||
@hugo --minify | ||
|
||
run-target: | ||
@mkdir -p vault content | ||
@rsync -avh $(path) ./vault/ --delete | ||
@obsidian-export ./vault/ ./content/ | ||
@hugo server |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# log.console.so | ||
|
||
## Getting Started | ||
|
||
This is our hugo repository for the log.console.so website. We use GitHub actions to automate the following: | ||
1. Turn Obsidian markdown files into general markdown syntax | ||
|
||
### Prerequisites |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.