diff --git a/src/jreleaser/distributions/mcs/snap/README.md.tpl b/src/jreleaser/distributions/mcs/snap/README.md.tpl new file mode 100644 index 00000000..4b569da9 --- /dev/null +++ b/src/jreleaser/distributions/mcs/snap/README.md.tpl @@ -0,0 +1,7 @@ +# Snap repo for MCS + +[![Get it from the Snap Store](https://snapcraft.io/static/images/badges/en/snap-store-white.svg)](https://snapcraft.io/maven-central-search) + +Snap configuration for {{projectNameCapitalized}} + +Builds with [https://snapcraft.io/{{distributionName}}/builds](https://snapcraft.io/{{distributionName}}/builds) diff --git a/src/jreleaser/distributions/mcs/snap/snap/snapcraft.yaml.tpl b/src/jreleaser/distributions/mcs/snap/snap/snapcraft.yaml.tpl new file mode 100644 index 00000000..d1c22a7c --- /dev/null +++ b/src/jreleaser/distributions/mcs/snap/snap/snapcraft.yaml.tpl @@ -0,0 +1,67 @@ +name: maven-central-search +version: {{projectVersion}} +summary: {{projectDescription}} +description: {{projectLongDescription}} + +grade: {{snapGrade}} +confinement: {{snapConfinement}} +base: {{snapBase}} +type: app + +apps: + {{distributionExecutable}}: + command: $SNAP/bin/{{distributionExecutable}} + {{#snapHasLocalPlugs}} + plugs: + {{#snapLocalPlugs}} + - {{.}} + {{/snapLocalPlugs}} + {{/snapHasLocalPlugs}} + {{#snapHasLocalSlots}} + slots: + {{#snapLocalSlots}} + - {{.}} + {{/snapLocalSlots}} + {{/snapHasLocalSlots}} + +{{#snapHasPlugs}} +plugs: + {{#snapPlugs}} + {{name}}: + {{#attributes}} + {{key}}: {{value}} + {{/attributes}} + {{/snapPlugs}} +{{/snapHasPlugs}} +{{#snapHasSlots}} +slots: + {{#snapSlots}} + {{name}}: + {{#attributes}} + {{key}}: {{value}} + {{/attributes}} + {{#hasReads}} + reads: + {{#reads}} + - {{.}} + {{/reads}} + {{/hasReads}} + {{#hasWrites}} + writes: + {{#writes}} + - {{.}} + {{/writes}} + {{/hasWrites}} + {{/snapSlots }} +{{/snapHasSlots}} +parts: + {{distributionExecutable}}: + plugin: dump + source: {{distributionUrl}} + source-checksum: sha256/{{distributionChecksumSha256}} + stage-packages: + - curl + +architectures: + - build-on: amd64 + run-on: amd64