-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Sync with upstream: 46cf5ab5d50070bd8df847e4887c377bc2e92fac
- Loading branch information
0 parents
commit f12de54
Showing
223 changed files
with
136,887 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,42 @@ | ||
name: Deploy Conference Web site | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout source | ||
uses: actions/checkout@v2 | ||
with: | ||
path: main | ||
- name: Setup node | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: 10.x | ||
- name: Install hexo dependencies | ||
run: | | ||
cd main | ||
npm install | ||
- name: Generate website | ||
run: | | ||
cd main | ||
npm run generate | ||
- name: Checkout gh-pages | ||
uses: actions/checkout@v2 | ||
with: | ||
path: gh-pages-pre | ||
ref: gh-pages | ||
fetch-depth: 0 | ||
- name: Publish to gh-pages | ||
run: | | ||
mv main/public gh-pages | ||
cp -r gh-pages-pre/.git gh-pages/ | ||
cd gh-pages | ||
git config --local user.email "bot@grusp.org" | ||
git config --local user.name "Bot" | ||
git add . | ||
git commit -m "Auto Deploy at `date +"%Y-%m-%d %H:%M"`" | ||
git push origin 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
.DS_Store | ||
Thumbs.db | ||
db.json | ||
*.log | ||
node_modules | ||
public/ | ||
.deploy*/ |
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,32 @@ | ||
image: node:12.18.3 | ||
|
||
cache: | ||
paths: | ||
- node_modules/ | ||
|
||
# created for initial tests; not used | ||
# deploy: | ||
# stage: deploy | ||
# before_script: | ||
# - npm install netlify-cli -g | ||
# - npm install | ||
# script: | ||
# - npx hexo clean && npx hexo g | ||
# - "LIVE_URL=$(netlify deploy --json --dir=public/ -s $NETLIFY_SITE_ID -a $NETLIFY_AUTH_TOKEN | grep -oP '(?<=\"deploy_url\": \")[^\"]*')" | ||
# - "curl -X POST -H 'Content-type: application/json' --data '{\"text\": \"$CI_PROJECT_NAME deployato con successo dal branch $CI_COMMIT_REF_NAME, $LIVE_URL\"}' $SLACK_WEBHOOK_URL" | ||
# only: | ||
# - branches | ||
# when: manual | ||
|
||
deploy_prod: | ||
stage: deploy | ||
before_script: | ||
- npm install netlify-cli -g | ||
- npm install | ||
script: | ||
- npm run generate | ||
- "LIVE_URL=$(netlify deploy --json --prod --dir=public/ -s $NETLIFY_SITE_ID -a $NETLIFY_AUTH_TOKEN | grep -oP '(?<=\"url\": \")[^\"]*')" | ||
- "curl -X POST $SLACK_WEBHOOK_URL -H 'Content-type: application/json' --data '{\"text\": \"Una nuova versione del sito è stata pubblicata con successo\"}'" | ||
only: | ||
refs: | ||
- master |
Oops, something went wrong.