Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/frokk/Neu-AppImage

Package Neutralino Application Into AppImage Format
https://github.com/frokk/Neu-AppImage

appimage appimage-builder neutralinojs

Last synced: 19 days ago
JSON representation

Package Neutralino Application Into AppImage Format

Awesome Lists containing this project

README

        

# Neu-AppImage
Package Neutralino Application Into AppImage Format

---

## From the Command Line

Running Neu AppImage from the command line has this basic form:

```bash
npx neu-appimage --exe --res --program-name --description --icon --categories --arch --out-dir [Optional Arguments]
```

You can directly build your AppImage from command line, available options are:

```html
NAME TYPE OPTIONAL DESCRIPTION
--exe NO Path To The Main Executable
--res NO Path To The "resource.neu" File
--files NO Path To Other Files To Include (seprated by comma, example: file1,file2,file3)
--program-name NO Name Of The Program
--generic-name YES Generic Name Of The Program
--description NO Description Of The Program
--icon NO Path To The Program Icon
--version YES Program Version (ex - 1.0.2-stable or 3.5)
--categories NO Category Of The Program (Seprated By Comma if multiple, example: cat1,cat2)
--working-dir YES The working directory to run the program in
--arch NO Program Architecture (x64 or x32)
--out-dir NO Path to directory to save AppImage in
--log YES Log the output of AppImage Tool.
--list-categories YES List Available Categories.
-V, --version YES Output the version number
-h, --help YES Display help for command
```

---

## API

```javascript
const { AppImage, STATUS_CODE } = require('neu-appimage');
```

### `new AppImage(executable, resource, files, outdir, options)`

`executable` is the path to the Main Neutralino Generated Binary.

`resource` is the path to the `resource.neu` file Generated by Neutralino.

`files` is an Array of Strings containing Path To Files To Be Included in AppImage.

`outdir` is a String Path to the directory in which to save the AppImage To.

`options` is an object that can contain following fields:

* `programName` - Name of the program (ex - `"FireFox"`).
* `genericName` - Generic Name of the program (ex - `"Web Browser"`).
* `description` - Description of the program (ex - `"Free and open-source web browser"`).
* `icon` - Path to the icon file (`.png`) in 512x512 or 256x256 resolution (ex - `"/path/to/icon.png"`).
* `version` - Version of your program (ex - 0.3.9-beta or 1.3).
* `categories` - Array of Strings Containing Category of the program (ex - `["Utility", "Network"]`).
* These are the available `categories`
- Audio
- Video
- AudioVideo
- Development
- Education
- Game
- Graphics
- Network
- Office
- Science
- Settings
- System
- Utility
* `workingDir` - The working directory to run the program in (ex - `"~/"`).
* `arch` - Architecture of your program which the AppImage will inherit (only `x86_64` & `i386` are supported currently) (ex - `"x86_64"`).
* `showAppImgToolOutput` - if true, output of the [AppImage Tool](https://github.com/AppImage/AppImageKit) will be showed on console (can be useful for debugging if command fails) (ex - `false`).

### `myAppImageInstance.build()`
Builds the AppImage & returns Object containing information related to Build

`code` - Return Code is `STATUS_CODE.SUCCESS` if AppImage Was Created Successfully else it can return:
* `STATUS_CODE.PATH_NOT_FOUND` - If a File/Folder doesn't Exist.
* `STATUS_CODE.UNSUPPORTED_OS_ARCHITECTURE` - If the machine running the code is not `x64` or `x32` Bit.
* `STATUS_CODE.UNSUPPORTED_ARCHITECTURE` - If the `arch` property in `options` is not `x64` or `x32`.
* `STATUS_CODE.UNSUPPORTED_OS` - If the machine running the code is not Linux.
* `STATUS_CODE.UNKNOWN` - If the error is Unknown.

`text` - Path to the generated AppImage if successfully created one, else Description of the Error Occured.

---

## Found Bugs?

You can report bugs/issues [Here](https://github.com/DEVLOPRR/Neu-AppImage/issues/new/choose)

---

# Thanks