mangaplus-parser 0.2.4

Reads mangaplus data from stdin and outputs as JSON
Documentation
image: "sseemayer/rust-musl-builder-mingw:latest"

stages:
  - build
  - deploy

linux-musl-x86:
  stage: build
  cache:
    key: linux-musl-x86
    paths:
    - target
  artifacts:
    paths:
      - target/x86_64-unknown-linux-musl/release/mangaplus-parser
  script:
    - cargo build --release --target x86_64-unknown-linux-musl

# linux-musl-i686:
#   stage: build
#   artifacts:
#     paths:
#       - target/i686-unknown-linux-musl/release/mangaplus-parser
#   script:
#     - cargo build --release --target i686-unknown-linux-musl

windows-mingw:
  stage: build
  cache:
    key: windows-mingw-x86
    paths:
    - target
  artifacts:
    paths:
      - target/x86_64-pc-windows-gnu/release/mangaplus-parser.exe
  script:
    - cargo build --release --target x86_64-pc-windows-gnu

pages:
  stage: deploy
  image: rustlang/rust:nightly
  cache:
    key: pages
    paths:
    - target
  script:
    - PATH="$PATH:$(pwd)/target/bin"
    - maybe_install(){ if ! ($1 --help); then cargo install $1 --root target; fi; }
    - time maybe_install static-compress
    - time maybe_install oxipng
    - "# Finished install, generate docs"
    - cargo doc --all --document-private-items --verbose
    - cp -r target/doc public
    - echo 'Redirecting to mangaplus_parser...<link rel="prerender" href="mangaplus_parser/index.html"/><meta http-equiv="refresh" content="3; url=mangaplus_parser/index.html"/><link rel=prefetch href=rustdoc.css /><link rel=prefetch href=normalize.css /><link rel=prefetch href=rust-logo.png />' > public/index.html
    - "# Compressing doc resources"
    - COMPRESS='public/**/*.{html,css,js,svg,txt}'
    - time static-compress -j 4 -c brotli -q 11 "$COMPRESS"
    - time static-compress -j 4 -c gzip -q 9 "$COMPRESS"
    - time oxipng -Z $(find public -name '*.png')
  allow_failure: false
  artifacts:
    paths:
    - public