diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 5f83f6e..0000000 --- a/.travis.yml +++ /dev/null @@ -1,52 +0,0 @@ -dist: xenial - -branches: - only: - - master - -services: - - docker - -node_js: 10 - -install: - # Install Hugo - - export HUGO_LATEST_RELEASE=$(curl -s https://github.com/gohugoio/hugo/releases/latest | sed 's@.*releases/tag/v\([^"]*\).*@\1@') - - curl --silent --location https://github.com/gohugoio/hugo/releases/download/v${HUGO_LATEST_RELEASE}/hugo_${HUGO_LATEST_RELEASE}_Linux-64bit.tar.gz | sudo tar xvzf - -C /usr/local/bin/ hugo - - # Install markdownlint and markdown-link-check - - npm install -g markdownlint-cli markdown-link-check > /dev/null - - # Remove public directory if exists - - rm -rf public || exit 0 - -script: - # Get local IP - - export HOST_IP_ADDRESS="$(ip -4 addr show docker0 | sed -n 's/.* inet \([^/]*\).*/\1/p')" - - # Generate pages by Hugo and run it's web server - - hugo server --bind ${HOST_IP_ADDRESS} --baseURL http://${TRAVIS_REPO_SLUG##*/} & - - # Check links on generated pages - - docker run -it --rm --add-host ${TRAVIS_REPO_SLUG##*/}:${HOST_IP_ADDRESS} linkchecker/linkchecker --check-extern http://${TRAVIS_REPO_SLUG##*/}:1313 - - # Markdown check - - 'echo "{ \"line-length\": false }" > /tmp/markdownlint_config.json' - - find . -path ./themes -prune -o -name "*.md" -print0 | xargs -0 markdownlint -c /tmp/markdownlint_config.json - - # Link Checks - - 'echo "{ \"ignorePatterns\": [{ \"pattern\": \"^https://www.linkedin.com\" }] }" > /tmp/markdown-link-check.json' - - find . -path ./themes -prune -o -name "*.md" -print0 | xargs -0 markdown-link-check --config /tmp/markdown-link-check.json --quiet - - # Generate pages - - hugo - -# Deploy to GitHub pages -deploy: - provider: pages - fqdn: ${TRAVIS_REPO_SLUG##*/} - skip_cleanup: true - github_token: $GITHUB_TOKEN - local_dir: public - on: - branch: master