2015-12-14 14:56:18 +01:00
2015-11-17 20:09:07 +01:00
2015-12-14 14:56:18 +01:00
2015-08-30 15:34:24 +02:00
2015-11-17 20:09:07 +01:00
2015-11-17 20:09:07 +01:00
2015-12-14 14:56:18 +01:00

NAME

love-release -- Bash script to generate LÖVE game releases
Automate LÖVE Game Distribution.
MIT-licensed.

INSTALLATION

Dependencies

  • Bash 4
  • GNU getopt and GNU readlink. OSX/BSD users need to install them. You can add GETOPT_COMPATIBLE= in your shell rc to prevent incompatibilities.
  • curl, zip and unzip.
  • lua to read the configuration. You also need Wine to get icons and installer for Windows, the Debian packaging utilities for Debian and the Android SDK to build a package for Android.

Build and install

First clone the repository, then you have two choices:

  • you can build the script and install it on your system, and benefit of command-line completion, man page and extensibility,
  • or make an embedded version with every thing you need in one file.

Alternatively, you can change the installation directories by editing the Makefile.

# Install on your system (assumes root rights)
make
make install

# All-in-one
make embedded

To remove love-release, if you haven't changed the default installation directories, run make remove.

SYNOPSIS

love-release.sh [-ADLMW] [-t project_title] [-r release_dir] [-l love_version] [FILES...]

DESCRIPTION

love-release.sh can be used to generate LÖVE game applications and get over the fastidious zipping commands you had to do.

The script fully supports Windows, MacOS either on x86 or x64, Debian and Android packages.
It needs an Internet connection to download LÖVE files.

CONFIGURATION

You can install lua and add a conf.lua to your project to get automatic releases. See the conf.lua file included to see how configuration works.

OPTIONS

-h Print a short help
--help Print this longer help

OPERATING SYSTEMS

-A Create an Android package. In order to create an Android package, you must have installed the Android SDK. See Building LÖVE for Android, but there is no need to install the LÖVE port to Android, as the script will handle this by itself. You also might want to provide more informations about it. See the ANDROID section below.

-D Create a deb package. Aimed at Debian and Ubuntu derivatives. In order to create a Debian package, you must provide more informations about it. See the DEBIAN section below.

-L Create a plain LÖVE file. It is just a zip of your sources, renamed in *.love. Mostly aimed at Linux players or developers and the most common distribution process.

-M Create MacOS application. Starting with LÖVE 0.9.0, LÖVE no longer supports old x86 Macintosh. If you are targeting one of these, your project must be developped with LÖVE 0.8.0 or lower. Depending on the LÖVE version used, the script will choose which one, between x64 only or Universal Build to create.

-W Create Windows application. Starting with LÖVE 0.8.0, a release is specially available for Windows x64. If you are targeting one of these, your project must be developed with LÖVE 0.8.0 or newer. Remember that x86 is always backwards compatible with x64. Depending on the LÖVE version used, the script will choose which one, between x64 and x86 or x86 only to create.
-W32 Create Windows x86 executable only
-W64 Create Windows x64 executable only

PROJECT OPTIONS

You can use the option of a module and append a long option from this list to set a specific option for a module. For example, the option --Wauthor will set the author's name for Windows only.

-a, --author Set the project's author.

-d, --description Set the project's description.

-e, --email Set the author's email.

-i, --icon Path to icons.

-l, --love LÖVE version. Default is 0.9.2. Starting with LÖVE 0.8.0, a release is specially available for Windows x64. Starting with LÖVE 0.9.0, LÖVE no longer supports old x86 Macintosh.

-p, --pkg Set the project's identity.

-r, --release Set the release directory. By default, a subdirectory called releases is created.

-t, --title Set the project's title. By default, the name of the current directory is used.

-u, --url Set the project's homepage.

-v, --version Set your project's version.

-x, --exclude Exclude file or directory. Use backslashes or quotes to avoid the shell filename substitution, so that the name matching is performed by zip at all directory levels.

WINDOWS

You can create an installer. If you dont, you will have zip of a folder containing your game executable and its dlls. Creating installers and using icons require Wine to be installed. When the script installs Resource Hacker or Inno Setup, an install wizard GUI will appear. Please let everything as is, do not uncheck checkboxes or replace installation directory.
--Wicon Path to an ico file to use.
--Winstaller Create an installer with Inno Setup.
--Wappid Your game ID. You can use a GUID/UUID and generate one with uuidgen. It should remain the same between updates. Mandatory if using an installer, not needed for a simple zip.
--Wauthor Set the maintainers name. Mandatory if using an installer, not needed for a simple zip.
--Wpkg Set the name of your package. Mandatory if using an installer, not needed for a simple zip.
--Wversion Set the version of your package. Mandatory if using an installer, not needed for a simple zip.

MAC OS X

--Micon Path to an icns file to use.
--Mauthor Set the maintainers name. Provide it for OS X CFBundleIdentifier.

DEBIAN

--Dicon Path to a single folder where icons are stored. To be properly recognized, icons filename must contain YYxYY, where YY is the resolution of the icon. SVG files are recognized if suffixed with .svg. Other files will be ignored.
--Demail Set the maintainers email.
--Dauthor Set the maintainers name.
--Dpkg Set the name of the package and the command that will be used to launch your game. By default, it is the name of your project converted to lowercase, with eventual spaces replaced by dashes.
--Dversion Set the version of your package.

ANDROID

Note that every argument passed to the options should be alphanumerical, with eventual underscores (i.e. [a-zA-Z0-9_]), otherwise you'll get errors.
--Aicon Path to a single folder where icons are stored. The script will first look up for filename that contains 42x42, 72x72, 96x96 or 144x144. It will then search the icon directory for subdirectories like drawable-mdpi, drawable-hdpi, drawable-xhdpi and drawable-xxhdpi to find an ic_launcher.png image.
OUYA icon (size 732x412, or drawable-xhdpi/ouya_icon.png) is supported.
--Aactivity The name of the class that extends GameActivity. By default it is the name of the project with Activity appended, eventual spaces and dashes replaced by underscores.
--Aauthor Set the maintainers name. It must be only alphanumerical characters, with eventual underscores.
--Apkg Set the name of the package. By default, it is the name of your project, with eventual spaces replaced by underscores.
--Aversion Set the version of your package.
--Aupdate Update the love-android-sdl2.git repository used in the cache.

OTHERS

--clean Clean the cache located in ~/.cache/love-release. One can replace the LÖVE binaries there.

MODULES

The script is modular. Each different platform is handled by a subscript stored in scripts. If youd like to add the support of another platform, or write your own build script, see modules.md.

ICONS

The script doesnt yet handle the process of creating icons, but if provided it can use them.

  • if you want to create MacOS icons (.icns), and you are
    • running MacOS, then check iconutil.
    • running GNU/Linux, then check libicns.
  • if you want to create Windows icons (.ico), you can
    • use icoutils to create the icon,
    • then Wine and Resource Hacker to set the icon. This last step can be automatically done, assuming Wine is installed.
Description
💌 Lua script that makes LÖVE game release easier
Readme MIT 318 KiB
Languages
Lua 100%