Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Fix 463 and rename appimage #481

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
RedStoneMango wants to merge 3 commits into javapackager:master
base: master
Choose a base branch
Loading
from RedStoneMango:fix-463-and-rename-appimage
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
View file Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,8 @@
import java.io.IOException;

public class GenerateAppImage extends ArtifactGenerator<LinuxPackager> {

private static final int IMAGETOOL_VERSION = 13;
private static final String IMAGETOOL_URL = "https://github.com/AppImage/AppImageKit/releases/download/" + IMAGETOOL_VERSION + "/appimagetool-%s.AppImage";

private static final String IMAGETOOL_URL = "https://github.com/AppImage/appimagetool/releases/download/continuous/appimagetool-%s.AppImage";

public GenerateAppImage() {
super("AppImage");
Expand Down Expand Up @@ -41,12 +40,13 @@ protected File doApply(LinuxPackager packager) throws Exception {
File appFolder = packager.getAppFolder();
File outputFolder = packager.getOutputDirectory();
String name = packager.getName();
String version = packager.getVersion();
File executable = packager.getExecutable();
File assetsFolder = packager.getAssetsFolder();
File iconFile = packager.getIconFile();

// output AppImage file
File appImage = new File(outputFolder, name + ".AppImage");
File appImage = new File(outputFolder, name + "_" + version + ".AppImage");

// AppDir folder
File appDir = new File(assetsFolder, "AppDir");
Expand Down
View file Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ protected File doApply(LinuxPackager packager) throws Exception {
builder.build(outputDirectory);

// renames generated RPM file if created
String suffix = "-1." + arch + ".rpm";
String suffix = "-1." + getRpmArchString(arch) + ".rpm";
File originalRpm = new File(outputDirectory, name + "-" + version + suffix);
File rpm = null;
if (originalRpm.exists()) {
Expand Down Expand Up @@ -129,4 +129,10 @@ private void addDirectory(Builder builder, String parentPath, File directory, Li
}
}

private String getRpmArchString(Architecture arch) {
if (arch == null) return "null";

return arch.toString().toLowerCase(); // Without Locale to match the redline_rpm way of handling conversion
}

}

AltStyle によって変換されたページ (->オリジナル) /