Skip to content
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
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
*.chm
*.exe
*.ini
build/
dist/
rules.ini
belvedere.sublime-workspace
21 changes: 10 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,25 +10,24 @@ An automated file manager for Windows

See [LICENSE.txt](https://github.com/mshorts/belvedere/blob/master/LICENSE.txt) for licensing details.

#How to build the installer manually.
### How to build the installer manually.

1. Clone the repo: `git clone git://github.com/mshorts/belvedere.git`
2. Download and install [NSIS](http://prdownloads.sourceforge.net/nsis/nsis-2.46-setup.exe?download)
3. Download [KIllProc plug-in for NSIS](http://code.google.com/p/mulder/downloads/detail?name=NSIS-KillProc-Plugin.2011-04-09.zip&can=4&q=)
4. Download and install [Microsoft HTML Help Workshop 1.3](http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=21138).
5. Download and install [AutoHotkey_L](http://www.autohotkey.com/download/).
6. Download and install [Compile_AHK](http://www.autohotkey.com/forum/topic22975.html).
7. Compile Belvedere.ahk with Compile_AHK(in the root of the repo) and move the .exe into the /installer directory.
8. Compile /help/Belvedere Help.hhp with HTML Help Workshop and move the .chm to the /installer directory.
9. Compile /installer/install.nsi
10. Make sure to test the installer.
4. Download and install [AutoHotkey_L](http://www.autohotkey.com/download/).
5. Download and install [Compile_AHK](http://www.autohotkey.com/forum/topic22975.html).
6. Compile Belvedere.ahk with Compile_AHK(in the root of the repo) and move the .exe into the /installer directory.
7. Compile /help/Belvedere Help.hhp with HTML Help Workshop and move the .chm to the /installer directory.
8. Compile /installer/install.nsi
9. Make sure to test the installer.

#How to build the installer automatically.
### How to build the installer automatically.

1. Run build.ahk
1. Run build-tools/build.ahk
2. Find the installer in the /dist directory.

#How to run.
### How to run.

1. Download the installer -or-
2. Install AutoHotkey and run Belvedere.ahk.
8 changes: 8 additions & 0 deletions belvedere.sublime-project
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"folders":
[
{
"path": "/I/dev/projects/belvedere"
}
]
}
10 changes: 10 additions & 0 deletions build-tools/build-GUI-build.ahk
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
Gui, 2:Add, Edit, x12 y10 w450 h130 +cBlack +ReadOnly +R10
Gui, 2:Add, Button, x187 y150 w100 h30 gCancel, Cancel
; Generated using SmartGUI Creator 4.0
Gui, 2:Show, x448 y272 h196 w479, New GUI Window
Return

2GuiClose:
ExitApp

Cancel:
21 changes: 21 additions & 0 deletions build-tools/build-GUI-welcome.ahk
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
Gui, 1:Add, Text, x2 y0 w270 h20 +ReadOnly +ReadOnly +Center, Belvedere Installer Build Tool
Gui, 1:Add, Picture, x2 y20 w270 h270 , I:\dev\projects\belvedere\resources\both.png
Gui, 1:Add, Button, x282 y10 w100 h50 gBuild, &Build
Gui, 1:Add, Button, x282 y70 w100 h30 , &Configure
Gui, 1:Add, Button, x282 y110 w100 h30 g1GuiClose, &Exit
Gui, 1:Add, Text, x392 y10 w190 h50 , Build the installer using the default setting. The build tool will look for dependencies automatically.
Gui, 1:Add, Text, x392 y70 w190 h30 , Configure the build environment manually.
Gui, 1:Add, Text, x392 y110 w190 h30 , Close the build tool.
Gui, 1:Add, Text, x282 y150 w300 h140 , Copyright 2012 Dorian Alexander Patterson.`nDistrubed under the GNU Public License version 3. See LICENSE.txt for details.`nWritten in AutoHotkey.
; Generated using SmartGUI Creator 4.0
Gui, 1:Show, Center h298 w600, %buildToolsName%
Return

1GuiClose:
ExitApp
return

Build:
Gui, 1:Cancel
#Include build-GUI-build.ahk
Return
141 changes: 141 additions & 0 deletions build-tools/build.ahk
Original file line number Diff line number Diff line change
@@ -0,0 +1,141 @@
; Build script for Belvedere
; Version 0.3.1
; Author: Dorian Alexander Patterson <imaginationc@gmail.com>
; Requires: AutoHotkey_L 1.1.07.01+
;
; Copyright 2012 Dorian Alexander Patterson
;
; This program is free software: you can redistribute it and/or modify
; it under the terms of the GNU General Public License as published by
; the Free Software Foundation, either version 3 of the License, or
; (at your option) any later version.
;
; This program is distributed in the hope that it will be useful,
; but WITHOUT ANY WARRANTY; without even the implied warranty of
; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
; GNU General Public License for more details.
;
; You should have received a copy of the GNU General Public License
; along with this program. If not, see <http://www.gnu.org/licenses/>.

; Set up build environment
#NoEnv
#SingleInstance ignore
#NoTrayIcon
SetWorkingDir ..
buildDir = %A_WorkingDir%\build
buildToolsDir = %A_WorkingDir%\build-tools
;buildToolsName = Belvedere Installer Build Tool
installerDir = %A_WorkingDir%\installer
helpProject = %A_WorkingDir%\help\Belvedere Help.hhp
distDir = %A_WorkingDir%\dist
executableName = Belvedere.exe
installerScript = %buildDir%\installer.nsi

SetWorkingDir, %buildToolsDir%
#Include configure.ahk

; After configuration, actually build things.
SetWorkingDir, ..
; Clean old build files.
IfExist, %BuildDir%
{
FileAppend, Clean old build files...`n, *
FileRemoveDir, %BuildDir%, 1
}
; Create build directory.
try
{
FileAppend, Creating build directory: %BuildDir%`n, *
FileCreateDir, %BuildDir%
}
catch e
{
FileAppend, Could not create the build directory. Check your permissions.`n, *
ExitApp, 1
}

; Compile executable.
FileAppend, Building Belvedere.exe...`n, *
; 64-Bit workaround. Compile_AHK doesn't play nice. Use ahk2exe directly.
if (Is64Bit())
{
try
{
Program := Dependencies.ahk2exe
Target = %Program% /in %A_WorkingDir%\Belvedere.ahk
RunWait, %Target%
}
catch e
{
FileAppend, Could not build Belvedere.exe. Check your permissions.`n, *
ExitApp, 1
}
}
; 32-bit. Use Compile_AHK.
else
{
try
{
Program := Dependencies.compileahk
Target = %Program% /auto %A_WorkingDir%\Belvedere.ahk
RunWait, %Target%
}
catch e
{
FileAppend, Could not build Belvedere.exe. Check your permissions.`n, *
ExitApp, 1
}
}

; Move executable to build directory.
FileMove, %A_WorkingDir%\%executableName%, %BuildDir%

; Compile help.
FileAppend, Building help...`n, *
try
{
Program := Dependencies.hhc
Target = "%Program%" "%helpProject%"
RunWait, %Target%
}
catch e
{
FileAppend, Could not build help. Check your permissions.`n, *
ExitApp, 1
}

; Copy installer files to build directory.
try
{
FileCopy, %InstallerDir%\*.*, %BuildDir%\*.*
}
catch e
{
FileAppend, Could not copy installation files. Check your permissions.`n, *
ExitApp, 1
}

; Compile the installer.
FileAppend, Building installer...`n, *
try
{
Program := Dependencies.makensis
Target = "%Program%" /V4 "%InstallerScript%"
RunWait, %Target%
}
catch e
{
FileAppend, Could not build installer. Check your permissions.`n, *
ExitApp, 1
}

OnExit:
If (A_ExitReason == "Error")
{
MsgBox, Unable to compile the installer. Please check the logs.
}
Else
{
MsgBox, Installer compiled successfully!`nYou can find the installer in %distDir%
}
Loading