blog/.gitlab-ci.yml

20 lines
544 B
YAML
Raw Normal View History

# Use latest version of Node.js
image: node:latest
2016-02-29 14:25:06 +00:00
2016-02-29 14:25:06 +00:00
pages:
cache: # add cache to 'node_modules' for speeding up builds
2016-02-29 14:25:06 +00:00
paths:
- node_modules/ # Node modules and dependencies
2016-02-29 14:25:06 +00:00
script:
- npm install hexo-cli -g
- npm install
- hexo deploy # deploy the site
- find public -type f -iregex '.*\.\(htm\|html\|txt\|text\|js\|css\)$' -execdir gzip -f --keep {} \; # Compress files
2016-02-29 14:25:06 +00:00
artifacts:
paths:
- public # deploy to the 'public' folder
2016-02-29 14:25:06 +00:00
only:
- master # this job will affect only the 'master' branch