mirror of
https://github.com/jlengrand/jreleaser.git
synced 2026-03-10 08:31:24 +00:00
[assemble] Update package templates. Relates to #225
This commit is contained in:
@@ -63,6 +63,7 @@ parts:
|
||||
source: {{distributionUrl}}
|
||||
source-checksum: sha256/{{distributionChecksumSha256}}
|
||||
stage-packages:
|
||||
- curl
|
||||
- openjdk-{{distributionJavaVersion}}-jre
|
||||
- ca-certificates
|
||||
- ca-certificates-java
|
||||
|
||||
@@ -58,4 +58,6 @@ parts:
|
||||
{{distributionExecutable}}:
|
||||
plugin: dump
|
||||
source: {{distributionUrl}}
|
||||
source-checksum: sha256/{{distributionChecksumSha256}}
|
||||
source-checksum: sha256/{{distributionChecksumSha256}}
|
||||
stage-packages:
|
||||
- curl
|
||||
@@ -21,11 +21,11 @@ class {{brewFormulaName}} < Formula
|
||||
|
||||
def install
|
||||
libexec.install Dir["*"]
|
||||
bin.install_symlink "#{libexec}/{{distributionExecutable}}"
|
||||
bin.install_symlink "#{libexec}/bin/{{distributionExecutable}}"
|
||||
end
|
||||
|
||||
test do
|
||||
output = shell_output("#{libexec}/{{distributionExecutable}} --version")
|
||||
output = shell_output("#{bin}/{{distributionExecutable}} --version")
|
||||
assert_match "{{projectVersion}}", output
|
||||
end
|
||||
end
|
||||
|
||||
@@ -9,10 +9,12 @@ LABEL {{.}}
|
||||
{{/dockerPreCommands}}
|
||||
|
||||
COPY assembly/* /
|
||||
RUN chmod +x /{{distributionExecutable}}
|
||||
RUN chmod +x {{distributionArtifactName}}/bin/{{distributionExecutable}}
|
||||
|
||||
{{#dockerPostCommands}}
|
||||
{{.}}
|
||||
{{/dockerPostCommands}}
|
||||
|
||||
ENTRYPOINT ["/{{distributionExecutable}}"]
|
||||
ENV PATH="${PATH}:/{{distributionArtifactName}}/bin"
|
||||
|
||||
ENTRYPOINT ["/{{distributionArtifactName}}/bin/{{distributionExecutable}}"]
|
||||
@@ -5,13 +5,15 @@
|
||||
"license": "{{projectLicense}}",
|
||||
"url": "{{distributionUrl}}",
|
||||
"hash": "sha256:{{distributionChecksumSha256}}",
|
||||
"bin": "{{artifactFileName}}",
|
||||
"extract_dir": "{{projectName}}-{{projectVersion}}",
|
||||
"env_add_path": "bin",
|
||||
"checkver": {
|
||||
"url": "{{scoopCheckverUrl}}",
|
||||
"re": "v([\\d.]+)"
|
||||
"re": "v([\\d.]+).zip"
|
||||
},
|
||||
"autoupdate": {
|
||||
"url": "{{scoopAutoupdateUrl}}",
|
||||
"extract_dir": "{{projectName}}-$version",
|
||||
"hash": {
|
||||
"url": "$url.sha256"
|
||||
}
|
||||
|
||||
@@ -10,7 +10,7 @@ type: app
|
||||
|
||||
apps:
|
||||
{{distributionExecutable}}:
|
||||
command: $SNAP/{{artifactFileName}}
|
||||
command: $SNAP/bin/{{distributionExecutable}}
|
||||
{{#snapHasLocalPlugs}}
|
||||
plugs:
|
||||
{{#snapLocalPlugs}}
|
||||
@@ -56,9 +56,8 @@ slots:
|
||||
{{/snapHasSlots}}
|
||||
parts:
|
||||
{{distributionExecutable}}:
|
||||
plugin: nil
|
||||
override-build: |
|
||||
wget -O $SNAPCRAFT_PART_INSTALL/{{artifactFileName}} {{distributionUrl}}
|
||||
snapcraftctl set-version "{{projectVersion}}"
|
||||
build-packages:
|
||||
- wget
|
||||
plugin: dump
|
||||
source: {{distributionUrl}}
|
||||
source-checksum: sha256/{{distributionChecksumSha256}}
|
||||
stage-packages:
|
||||
- curl
|
||||
|
||||
Reference in New Issue
Block a user