When I install my snap it will not print. It goes to print but then fails with:
java.awt.print.PrinterIOException
But the jar works fine when it is just a executable jar.
Here is my Yaml:
name: highlighterpdf
title: HighlighterPdf
version: 1.0.2
summary: Highiight the text in a Pdf.
description:
HighlighterPdf is a free and open source software application that you can use to
highlight text in your pdf document. You can select text in a colour of your choice
and then save it.
confinement: strict
grade: stable
base: core18
apps:
highlighterpdf:
extensions: [gnome-3-28]
command: highlighterpdf.sh
environment:
JAVA_HOME: $SNAP/usr/lib/jvm/java-11-openjdk-amd64
PATH: $JAVA_HOME/bin:$PATH
plugs:
- home
- network
- cups-control
parts:
highlighterpdf:
source: https://github.com/gerry136/highlighterpdf.git
plugin: dump
stage-packages:
- unzip
- openjdk-11-jdk
(NEEDS REVIEW) confinement ‘classic’ not allowed. If your snap needs classic confinement to function, please make a request for this snap to use classic by creating a new topic in the forum using the ‘store-requests’ category and detail the technical reasons why classic is required.
confinement ‘classic’ not allowed with plugs/slots
The denial indicates your snap should plugs: [ cups-control ]. Do that and then run: sudo snap connect highlighterpdf:cups-control and it will hopefully work for you.
There is a known bug with snappy-debug that it is not recommending the cups-control interface (specifically, the access is in an AppArmor abstraction and snappy-debug doesn’t currently look at abstractions included in the snapd policy). I’ll take a look at fixing that soon.
name: highlighterpdf
title: HighlighterPdf
version: 1.0.2
summary: Highiight the text in a Pdf.
description:
HighlighterPdf is a free and open source software application that you can use to
highlight text in your pdf document. You can select text in a colour of your choice
and then save it.
confinement: strict
grade: stable
base: core18
apps:
highlighterpdf:
extensions: [gnome-3-28]
command: java -jar $SNAP/highlighterpdf.jar
environment:
JAVA_HOME: $SNAP/usr/lib/jvm/java-11-openjdk-amd64
PATH: $JAVA_HOME/bin:$PATH
plugs:
- cups-control
- home
- network
parts:
highlighterpdf:
source: https://github.com/gerry136/highlighterpdf.git
plugin: dump
build-packages:
- openjdk-11-jdk
stage-packages:
- unzip
- openjdk-11-jdk
- lpr