diff --git a/installer/install.sh b/installer/install.sh new file mode 100644 index 0000000..96a770a --- /dev/null +++ b/installer/install.sh @@ -0,0 +1,13 @@ +#!/bin/bash + +echo "Installing hotfix executable..." +cp hotfix ~/bin/hotfix +echo "Fixing permissions..." +chmod +x ~/bin/hotfix + +if [ -e ~/.hotfix.conf ]; then + echo "Configuration file ~/.hotfix.conf already exists" +else + echo "Installing configuration file..." + cp hotfix.conf ~/.hotfix.conf +fi diff --git a/installer/message b/installer/message new file mode 100644 index 0000000..4342f12 --- /dev/null +++ b/installer/message @@ -0,0 +1,5 @@ +This installer will put hotfix into the bin directory of the current user, ie. install it as ~/bin/hotfix. If the directory does not exist, it will be created. + +Most Linux distributions will automatically add ~/bin to the path if it exists. If hotfix isn't callable from the command line after restarting your shell and/or rebooting, please consult the documentation. + +Some basic aliases will be installed into ~/.hotfix.conf if the file doesn't already exist. diff --git a/selfie.conf b/selfie.conf new file mode 100644 index 0000000..106dab8 --- /dev/null +++ b/selfie.conf @@ -0,0 +1,32 @@ +package "NoccyLabs Hotfix" { + + output "setup-hotfix.run"; + destination "~/bin"; + + res "app.version" "v0.2"; + + // screens + screen "welcome" type="message" entry=true { + title "Welcome to the %{app.name} %{app.version} installer"; + text "@{installer:MESSAGE}"; + next "license"; + } + screen "license" type="license" { + title "Open Source License"; + license "GNU GPL v3 or later"; + text "@{installer:LICENSE}"; + } + + // bundles + bundle "installer" { + file "LICENSE" src="LICENSE"; + file "MESSAGE" src="installer/message"; + } + bundle "app" default=true { + file "hotfix"; + file "hotfix.conf"; + file "install.sh" src="installer/install.sh"; + script "install.sh"; + } + +}