Skip to content
This repository has been archived by the owner on Aug 20, 2021. It is now read-only.

[WIP] Doc updates #43

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 13 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ REPO := oscalkit
BINARY=oscalkit_$(GOOS)_$(GOARCH)

.DEFAULT_GOAL := $(BINARY)
.PHONY: test build-docker push $(BINARY) clean generate
.PHONY: test build-docker push $(BINARY) clean generate build-docs build docs

generate:
docker build -t $(NAMESPACE)/$(REPO):generate -f Dockerfile.generate .
Expand Down Expand Up @@ -47,6 +47,18 @@ build:
--build-arg BINARY=$(BINARY) \
-t $(NAMESPACE)/$(REPO):$(VERSION)-$(BUILD)-builder .

build-docs:
docker image build --no-cache -t $(NAMESPACE)/$(REPO):$(VERSION)-$(BUILD)-docs docs/

docs: build-docs
rm -rf docs/public
git worktree prune
rm -rf .git/worktrees/docs/public/
git worktree add -B gh-pages docs/public upstream/gh-pages
$(eval ID := $(shell docker create $(NAMESPACE)/$(REPO):$(VERSION)-$(BUILD)-docs))
@docker cp $(ID):/docs/public docs/
@docker rm $(ID) >/dev/null

# Builds binary for the OS/arch. Assumes that types have already been generated
# via the "generate" target
$(BINARY): build
Expand Down
1 change: 1 addition & 0 deletions docs/.dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
public/
10 changes: 10 additions & 0 deletions docs/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
FROM alpine:latest
RUN apk add --no-cache wget
WORKDIR /docs
RUN wget https://github.com/gohugoio/hugo/releases/download/v0.53/hugo_0.53_Linux-64bit.tar.gz && \
mkdir hugo && \
tar -zxvf hugo_0.53_Linux-64bit.tar.gz -C hugo/ && \
mv hugo/hugo /usr/local/bin/hugo && \
rm -rf hugo*
COPY . .
RUN hugo
20 changes: 0 additions & 20 deletions docs/content/account.md

This file was deleted.

207 changes: 0 additions & 207 deletions docs/content/blog/collapse.md

This file was deleted.

10 changes: 0 additions & 10 deletions docs/content/blog/inline-style.md

This file was deleted.

158 changes: 0 additions & 158 deletions docs/content/blog/messages.md

This file was deleted.

23 changes: 0 additions & 23 deletions docs/content/blog/prototyping.md

This file was deleted.

Loading