Skip to content

Commit 0d25db0

Browse files
author
M.Notter
committed
Updates deployment file.
1 parent 03e32da commit 0d25db0

File tree

2 files changed

+22
-20
lines changed

2 files changed

+22
-20
lines changed

.github/workflows/deploy.yml

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
- name: Setup Ruby
2020
uses: ruby/setup-ruby@v1
2121
with:
22-
ruby-version: '3.0.2'
22+
ruby-version: '3.2.2'
2323
- name: Enable bundler cache
2424
uses: actions/cache@v3
2525
with:
@@ -31,21 +31,23 @@ jobs:
3131
run: |
3232
gem install bundler
3333
bundle config path vendor/bundle
34+
bundle update
3435
bundle install --jobs 4 --retry 3
3536
npm install -g mermaid.cli
3637
- name: Setup deploy options
3738
id: setup
3839
run: |
3940
git config --global user.name "GitHub Action"
4041
git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
41-
if [[ ${GITHUB_REF} = refs/pull/*/merge ]]; then # pull request
42-
echo "::set-output name=SRC_BRANCH::${GITHUB_HEAD_REF}"
43-
echo "::set-output name=NO_PUSH::--no-push"
44-
elif [[ ${GITHUB_REF} = refs/heads/* ]]; then # branch, e.g. master, source etc
45-
echo "::set-output name=SRC_BRANCH::${GITHUB_REF#refs/heads/}"
42+
if [[ ${GITHUB_REF} = refs/pull/*/merge ]]; then
43+
echo "SRC_BRANCH=${GITHUB_HEAD_REF}" >> $GITHUB_OUTPUT
44+
echo "NO_PUSH=--no-push" >> $GITHUB_OUTPUT
45+
elif [[ ${GITHUB_REF} = refs/heads/* ]]; then
46+
echo "SRC_BRANCH=${GITHUB_REF#refs/heads/}" >> $GITHUB_OUTPUT
4647
fi
47-
echo "::set-output name=DEPLOY_BRANCH::gh-pages"
48+
echo "DEPLOY_BRANCH=gh-pages" >> $GITHUB_OUTPUT
4849
- name: Deploy website
49-
run: yes | bin/deploy --verbose ${{ steps.setup.outputs.NO_PUSH }}
50-
--src ${{ steps.setup.outputs.SRC_BRANCH }}
51-
--deploy ${{ steps.setup.outputs.DEPLOY_BRANCH }}
50+
run: |
51+
yes | bin/deploy --verbose ${{ steps.setup.outputs.NO_PUSH }} \
52+
--src ${{ steps.setup.outputs.SRC_BRANCH }} \
53+
--deploy ${{ steps.setup.outputs.DEPLOY_BRANCH }}

README.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -111,10 +111,10 @@ Why Jekyll? Read [Andrej Karpathy's blog post](https://karpathy.github.io/2014/0
111111
Assuming you have [Ruby](https://www.ruby-lang.org/en/downloads/) and [Bundler](https://bundler.io/) installed on your system (*hint: for ease of managing ruby gems, consider using [rbenv](https://github.com/rbenv/rbenv)*), first [fork](https://guides.github.com/activities/forking/) the theme from `github.com:alshedivat/al-folio` to `github.com:<your-username>/<your-repo-name>` and do the following:
112112

113113
```bash
114-
$ git clone [email protected]:<your-username>/<your-repo-name>.git
115-
$ cd <your-repo-name>
116-
$ bundle install
117-
$ bundle exec jekyll serve
114+
git clone [email protected]:<your-username>/<your-repo-name>.git
115+
cd <your-repo-name>
116+
bundle install
117+
bundle exec jekyll serve
118118
```
119119

120120
Now, feel free to customize the theme however you like (don't forget to change the name!).
@@ -149,7 +149,7 @@ Starting version [v0.3.5](https://github.com/alshedivat/al-folio/releases/tag/v0
149149

150150
If you need to manually re-deploy your website to GitHub pages, run the deploy script from the root directory of your repository:
151151
```bash
152-
$ ./bin/deploy
152+
./bin/deploy
153153
```
154154
uses the `master` branch for the source code and deploys the webpage to `gh-pages`.
155155

@@ -159,7 +159,7 @@ uses the `master` branch for the source code and deploys the webpage to `gh-page
159159

160160
If you decide to not use GitHub Pages and host your page elsewhere, simply run:
161161
```bash
162-
$ bundle exec jekyll build
162+
bundle exec jekyll build
163163
```
164164
which will (re-)generate the static webpage in the `_site/` folder.
165165
Then simply copy the contents of the `_site/` foder to your hosting server.
@@ -179,7 +179,7 @@ Firstly, from the deployment repo dir, checkout the git branch hosting your publ
179179

180180
Then from the website sources dir (commonly your al-folio fork's clone):
181181
```bash
182-
$ bundle exec jekyll build --destination $HOME/repo/publishing-source
182+
bundle exec jekyll build --destination $HOME/repo/publishing-source
183183
```
184184

185185
This will instruct jekyll to deploy the website under `$HOME/repo/publishing-source`.
@@ -207,9 +207,9 @@ If you installed **al-folio** as described above, you can upgrade to the latest
207207

208208
```bash
209209
# Assuming the current directory is <your-repo-name>
210-
$ git remote add upstream https://github.com/alshedivat/al-folio.git
211-
$ git fetch upstream
212-
$ git rebase upstream/v0.3.5
210+
git remote add upstream https://github.com/alshedivat/al-folio.git
211+
git fetch upstream
212+
git rebase upstream/v0.3.5
213213
```
214214

215215
If you have extensively customized a previous version, it might be trickier to upgrade.

0 commit comments

Comments
 (0)