-
-
Notifications
You must be signed in to change notification settings - Fork 993
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of https://github.com/sujaykundu777/devlopr-jekyll
- Loading branch information
Showing
11 changed files
with
214 additions
and
134 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 |
---|---|---|
|
@@ -4,20 +4,18 @@ | |
|
||
name: "Jekyll CI" | ||
|
||
|
||
# Controls when the workflow will run | ||
on: | ||
# Triggers the workflow on push or pull request events but only for the main branch | ||
push: | ||
branches: [ master ] | ||
branches: [master] | ||
pull_request: | ||
# The branches below must be a subset of the branches above | ||
branches: [ master ] | ||
branches: [master] | ||
# Triggers the workflow on push or pull request events but only for the main branch | ||
schedule: | ||
# Runs at 6am UTC every Monday | ||
- cron: '0 6 * * 1' | ||
|
||
- cron: "0 6 * * 1" | ||
|
||
jobs: | ||
# Check the Jekyll itself for errors and syntax | ||
|
@@ -28,12 +26,23 @@ jobs: | |
# Check that the Jekyll can actually build | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v3 | ||
- name: Build the site in the jekyll/builder container | ||
uses: actions/checkout@v4 | ||
- name: Build the site in the jekyll-docker container | ||
run: | | ||
docker run \ | ||
-v ${{ github.workspace }}:/srv/jekyll -v ${{ github.workspace }}/_site:/srv/jekyll/_site \ | ||
jekyll/builder:latest /bin/bash -c "chmod -R 777 /srv/jekyll && jekyll build --future" | ||
jvconseil/jekyll-docker:4.3.3 /bin/bash -c "chmod -R 777 /srv/jekyll && jekyll build --future" | ||
# - name: Build the site in the jekyll/builder container | ||
# run: | | ||
# docker run \ | ||
# -v ${{ github.workspace }}:/srv/jekyll -v ${{ github.workspace }}/_site:/srv/jekyll/_site \ | ||
# jekyll/builder:4.3.3 /bin/bash -c "chmod -R 777 /srv/jekyll && jekyll build --future" | ||
# - name: Build the site in the jekyll/builder container | ||
# run: | | ||
# docker run \ | ||
# -v ${{ github.workspace }}:/srv/jekyll -v ${{ github.workspace }}/_site:/srv/jekyll/_site \ | ||
# jekyll/builder:pages /bin/bash -c "chmod -R 777 /srv/jekyll && jekyll build --future" | ||
|
||
# Then check the markdown files are properly formatted | ||
analyse: | ||
|
@@ -43,13 +52,13 @@ jobs: | |
# Check markdown files are markdown-lint compliant | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
- name: Lint markdown files with markdown-lint | ||
uses: articulate/[email protected] | ||
with: | ||
# Includes some specific rules to ignore | ||
config: .github/workflows/markdownlint-config.json | ||
files: '_posts/**/*.md' | ||
files: "_posts/**/*.md" | ||
# Ignore the built website, might have some funky files | ||
ignore: _site/ | ||
# Try to fix basic errors | ||
|
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 |
---|---|---|
|
@@ -2,7 +2,7 @@ name: Deploy Site | |
|
||
on: | ||
push: | ||
branches: [ master ] | ||
branches: [master] | ||
workflow_dispatch: | ||
|
||
jobs: | ||
|
@@ -11,7 +11,7 @@ jobs: | |
outputs: | ||
target: ${{ steps.set-output.outputs.target }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v4 | ||
|
||
- name: get deployment target | ||
run: | | ||
|
@@ -44,37 +44,37 @@ jobs: | |
if: needs.set-deploy-type.outputs.target == 'gh-pages' | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Deploy Jekyll Site | ||
uses: sujaykundu777/[email protected].3 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GITHUB_REPOSITORY: ${{ secrets.GITHUB_REPOSITORY }} | ||
GITHUB_ACTOR: ${{ secrets.GITHUB_ACTOR }} | ||
- name: Deploy Jekyll Site | ||
uses: sujaykundu777/[email protected].5 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GITHUB_REPOSITORY: ${{ secrets.GITHUB_REPOSITORY }} | ||
GITHUB_ACTOR: ${{ secrets.GITHUB_ACTOR }} | ||
|
||
deploy-firebase: | ||
runs-on: ubuntu-latest | ||
needs: set-deploy-type | ||
if: needs.set-deploy-type.outputs.target == 'firebase' | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v4 | ||
|
||
- name: setup ruby | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
bundler-cache: true | ||
- name: setup ruby | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
bundler-cache: true | ||
|
||
- name: build jekyll | ||
run: | | ||
bundle install | ||
bundle exec jekyll build | ||
- name: build jekyll | ||
run: | | ||
bundle install | ||
bundle exec jekyll build | ||
- name: deploy to firebase | ||
uses: w9jds/firebase-action@master | ||
with: | ||
args: deploy --only hosting | ||
env: | ||
FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }} | ||
PROJECT_ID: ${{ secrets.FIREBASE_PROJECT_ID }} | ||
- name: deploy to firebase | ||
uses: w9jds/firebase-action@master | ||
with: | ||
args: deploy --only hosting | ||
env: | ||
FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }} | ||
PROJECT_ID: ${{ secrets.FIREBASE_PROJECT_ID }} |
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 |
---|---|---|
@@ -1 +1 @@ | ||
ruby-3.1.2 | ||
ruby-3.3.4 |
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 |
---|---|---|
@@ -1 +1 @@ | ||
none | ||
gh-pages |
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
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
Oops, something went wrong.