mirror of https://github.com/logos-co/roadmap.git
add Jenkinsfile for CI builds, extend Makefile
Signed-off-by: Jakub Sokołowski <jakub@status.im>
This commit is contained in:
parent
4ba156708a
commit
c18940ff99
|
@ -3,6 +3,7 @@ public
|
||||||
resources
|
resources
|
||||||
.idea
|
.idea
|
||||||
content/.obsidian
|
content/.obsidian
|
||||||
|
static/linkmap
|
||||||
assets/indices/linkIndex.json
|
assets/indices/linkIndex.json
|
||||||
assets/indices/contentIndex.json
|
assets/indices/contentIndex.json
|
||||||
linkmap
|
linkmap
|
||||||
|
|
|
@ -0,0 +1,47 @@
|
||||||
|
pipeline {
|
||||||
|
agent {
|
||||||
|
label 'linux'
|
||||||
|
}
|
||||||
|
|
||||||
|
options {
|
||||||
|
timestamps()
|
||||||
|
/* Prevent Jenkins jobs from running forever */
|
||||||
|
timeout(time: 10, unit: 'MINUTES')
|
||||||
|
/* manage how many builds we keep */
|
||||||
|
buildDiscarder(logRotator(
|
||||||
|
numToKeepStr: '20',
|
||||||
|
daysToKeepStr: '30',
|
||||||
|
))
|
||||||
|
disableConcurrentBuilds()
|
||||||
|
}
|
||||||
|
|
||||||
|
environment {
|
||||||
|
GIT_COMMITTER_NAME = 'status-im-auto'
|
||||||
|
GIT_COMMITTER_EMAIL = 'auto@status.im'
|
||||||
|
}
|
||||||
|
|
||||||
|
stages {
|
||||||
|
stage('Deps') {
|
||||||
|
steps {
|
||||||
|
sh 'make setup'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
stage('Build') {
|
||||||
|
steps {
|
||||||
|
/* Make hugo-obsidian available. */
|
||||||
|
withEnv(["PATH+EXTRA=${env.HOME}/go/bin"]) {
|
||||||
|
sh 'make build'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
stage('Publish Prod') {
|
||||||
|
steps {
|
||||||
|
sshagent(credentials: ['status-im-auto-ssh']) {
|
||||||
|
sh 'ghp-import -p public'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
23
Makefile
23
Makefile
|
@ -3,18 +3,27 @@
|
||||||
help: ## Show all Makefile targets
|
help: ## Show all Makefile targets
|
||||||
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
|
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
|
||||||
|
|
||||||
update: ## Update Quartz to the latest version on Github
|
setup: install-hugo-obsidian
|
||||||
|
|
||||||
|
install-hugo-obsidian:
|
||||||
go install github.com/jackyzha0/hugo-obsidian@latest
|
go install github.com/jackyzha0/hugo-obsidian@latest
|
||||||
|
|
||||||
|
update: install-hugo-obsidian ## Update Quartz to the latest version on Github
|
||||||
@git remote show upstream || (echo "remote 'upstream' not present, setting 'upstream'" && git remote add upstream https://github.com/jackyzha0/quartz.git)
|
@git remote show upstream || (echo "remote 'upstream' not present, setting 'upstream'" && git remote add upstream https://github.com/jackyzha0/quartz.git)
|
||||||
git fetch upstream
|
git fetch upstream
|
||||||
git log --oneline --decorate --graph ..upstream/hugo
|
git log --oneline --decorate --graph ..upstream/hugo
|
||||||
git checkout -p upstream/hugo -- layouts .github Makefile assets/js assets/styles/base.scss assets/styles/darkmode.scss config.toml data
|
git checkout -p upstream/hugo -- layouts .github assets/js assets/styles/base.scss assets/styles/darkmode.scss config.toml data
|
||||||
|
|
||||||
update-force: ## Forcefully pull all changes and don't ask to patch
|
update-force: install-hugo-obsidian ## Forcefully pull all changes and don't ask to patch
|
||||||
go install github.com/jackyzha0/hugo-obsidian@latest
|
|
||||||
@git remote show upstream || (echo "remote 'upstream' not present, setting 'upstream'" && git remote add upstream https://github.com/jackyzha0/quartz.git)
|
@git remote show upstream || (echo "remote 'upstream' not present, setting 'upstream'" && git remote add upstream https://github.com/jackyzha0/quartz.git)
|
||||||
git fetch upstream
|
git fetch upstream
|
||||||
git checkout upstream/hugo -- layouts .github Makefile assets/js assets/styles/base.scss assets/styles/darkmode.scss config.toml data
|
git checkout upstream/hugo -- layouts .github assets/js assets/styles/base.scss assets/styles/darkmode.scss config.toml data
|
||||||
|
|
||||||
serve: ## Serve Quartz locally
|
obsidian:
|
||||||
hugo-obsidian -input=content -output=assets/indices -index -root=. && hugo server --enableGitInfo --minify
|
hugo-obsidian -input=content -output=assets/indices -index -root=.
|
||||||
|
|
||||||
|
build: obsidian
|
||||||
|
hugo --enableGitInfo
|
||||||
|
|
||||||
|
serve: obsidian ## Serve Quartz locally
|
||||||
|
hugo server --enableGitInfo
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
baseURL = "https://quartz.jzhao.xyz/"
|
baseURL = "https://roadmap.logos.co/"
|
||||||
languageCode = "en-us"
|
languageCode = "en-us"
|
||||||
googleAnalytics = "G-XYFD95KB4J"
|
googleAnalytics = "G-XYFD95KB4J"
|
||||||
relativeURLs = false
|
relativeURLs = false
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
roadmap.logos.co
|
Loading…
Reference in New Issue