2019-08-24 02:41:55 +02:00
|
|
|
name: monolith
|
|
|
|
base: core18
|
2020-01-13 12:14:08 +01:00
|
|
|
# Version data defined inside the monolith part below
|
|
|
|
adopt-info: monolith
|
2019-08-24 02:41:55 +02:00
|
|
|
summary: Monolith - Save HTML pages with ease
|
|
|
|
description: |
|
|
|
|
A data hoarder's dream come true: bundle any web page into a single
|
|
|
|
HTML file. You can finally replace that gazillion of open tabs with
|
|
|
|
a gazillion of .html files stored somewhere on your precious little
|
|
|
|
drive.
|
|
|
|
Unlike conventional "Save page as…", monolith not only saves the
|
|
|
|
target document, it embeds CSS, image, and JavaScript assets all
|
|
|
|
at once, producing a single HTML5 document that is a joy to store
|
|
|
|
and share.
|
|
|
|
If compared to saving websites with wget -mpk, monolith embeds
|
|
|
|
all assets as data URLs and therefore displays the saved page
|
|
|
|
exactly the same, being completely separated from the Internet.
|
|
|
|
|
|
|
|
confinement: strict
|
|
|
|
|
2020-01-13 12:14:08 +01:00
|
|
|
# Building on armhf fails, so we specify all supported non-armhf architectures
|
|
|
|
architectures:
|
|
|
|
- build-on: amd64
|
|
|
|
- build-on: i386
|
|
|
|
- build-on: arm64
|
|
|
|
- build-on: ppc64el
|
|
|
|
- build-on: s390x
|
|
|
|
|
2019-08-24 02:41:55 +02:00
|
|
|
parts:
|
|
|
|
monolith:
|
|
|
|
plugin: rust
|
|
|
|
source: .
|
|
|
|
build-packages:
|
|
|
|
- libssl-dev
|
|
|
|
- pkg-config
|
2020-01-13 12:14:08 +01:00
|
|
|
override-pull: |
|
|
|
|
snapcraftctl pull
|
|
|
|
# Determine the current tag
|
|
|
|
last_committed_tag="$(git describe --tags --abbrev=0)"
|
|
|
|
last_committed_tag_ver="$(echo ${last_committed_tag} | sed 's/v//')"
|
|
|
|
# Determine the most recent version in the beta channel in the Snap Store
|
|
|
|
last_released_tag="$(snap info $SNAPCRAFT_PROJECT_NAME | awk '$1 == "beta:" { print $2 }')"
|
|
|
|
# If the latest tag from the upstream project has not been released to
|
|
|
|
# beta, build that tag instead of master.
|
|
|
|
if [ "${last_committed_tag_ver}" != "${last_released_tag}" ]; then
|
|
|
|
git fetch
|
|
|
|
git checkout "${last_committed_tag}"
|
|
|
|
fi
|
|
|
|
# set version number of the snap based on what we did above
|
|
|
|
snapcraftctl set-version $(git describe --tags --abbrev=0)
|
2019-08-24 02:41:55 +02:00
|
|
|
|
|
|
|
apps:
|
|
|
|
monolith:
|
|
|
|
command: monolith
|
|
|
|
plugs:
|
|
|
|
- home
|
|
|
|
- network
|
|
|
|
- removable-media
|