-
-
Notifications
You must be signed in to change notification settings - Fork 416
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* release/1.0.5: (45 commits) Bump version Update changelog More README tweaks Don't log empty lines from Syncthing Try and close Syncthing gracefully on application exit Tweak installer Tweak README Tweak build configurations Improve ConfigurationProvider logging Copy syncthing.exe from backup if newer than version in AppData Add logging to ConfigurationProvider Move to providing the title in the Window, not the VM Finish adding open source licenses window Don't allow saving settings to set autostart in Debug Make a start on a Third Party Components page Remove SyncthingPath from Configuration Correct initialisation order in ConfigurationProvider Add instructions to install .net 4.5 to standalone bit of REAMDE Add locking so ConfigurationProvider Fix Rakefile ...
- Loading branch information
Showing
58 changed files
with
2,185 additions
and
266 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,3 +41,4 @@ installer/syncthing.exe | |
*.tmp | ||
Coverage | ||
RefitStubs.cs | ||
SyncTrayzorPortable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
require 'rexml/document' | ||
begin | ||
require 'albacore' | ||
rescue LoadError | ||
warn "Please run 'gem install albacore --pre'" | ||
exit 1 | ||
end | ||
|
||
ISCC = '"C:\Program Files (x86)\Inno Setup 5\ISCC.exe"' | ||
|
||
BIN_DIR = 'bin/x64/Release' | ||
SRC_DIR = 'src/SyncTrayzor' | ||
INSTALLER_DIR = 'installer' | ||
INSTALLER = File.join(INSTALLER_DIR, 'SyncTrayzorSetup.exe') | ||
|
||
PORTABLE_OUTPUT_DIR = File.absolute_path('SyncTrayzorPortable') | ||
|
||
CONFIG = ENV['CONFIG'] || 'Release' | ||
PLATFORM = ENV['PLATFORM'] || 'x64' | ||
|
||
def cp_to_portable(src) | ||
dest = File.join(PORTABLE_OUTPUT_DIR, src) | ||
mkdir_p File.dirname(dest) unless File.exist?(File.dirname(dest)) | ||
cp src, dest | ||
end | ||
|
||
desc 'Build the project' | ||
build :build do |b| | ||
b.sln = 'src/SyncTrayzor.sln' | ||
b.target = [:Clean, :Build] | ||
b.prop 'Configuration', CONFIG | ||
b.prop 'Platform', PLATFORM | ||
end | ||
|
||
task :installer do | ||
rm INSTALLER if File.exist?(INSTALLER) | ||
sh ISCC, File.join(INSTALLER_DIR, 'installer.iss') | ||
end | ||
|
||
desc 'Create the portable release directory' | ||
task :portable do | ||
rm_rf PORTABLE_OUTPUT_DIR | ||
mkdir_p PORTABLE_OUTPUT_DIR | ||
|
||
Dir.chdir(BIN_DIR) do | ||
files = FileList[ | ||
'*.exe', | ||
'*.exe.config', | ||
'*.dll', | ||
'*.pdb', | ||
'*.pak', | ||
'*.dat', | ||
File.join('locales', '*'), | ||
].exclude('*.vshost.*') | ||
|
||
files.each do |file| | ||
cp_to_portable(file) | ||
end | ||
end | ||
|
||
cp File.join(SRC_DIR, 'Icons', 'default.ico'), PORTABLE_OUTPUT_DIR | ||
|
||
FileList['*.md', '*.txt'].each do |file| | ||
cp_to_portable(file) | ||
end | ||
|
||
Dir.chdir(INSTALLER_DIR) do | ||
FileList['syncthing.exe', '*.dll'].each do |file| | ||
cp_to_portable(file) | ||
end | ||
end | ||
|
||
puts 'Rewriting app.config' | ||
config_path = File.join(PORTABLE_OUTPUT_DIR, 'SyncTrayzor.exe.config') | ||
doc = File.open(config_path, 'r') do |f| | ||
doc = REXML::Document.new(f) | ||
REXML::XPath.first(doc, '/configuration/applicationSettings//setting[@name="PortableMode"]/value').text = 'True' | ||
doc | ||
end | ||
File.open(config_path, 'w') do |f| | ||
doc.write(f) | ||
end | ||
end | ||
|
||
desc 'Build and package everything' | ||
task :package => [:build, :installer, :portable] | ||
|
||
desc 'Remove portable and installer' | ||
task :clean do | ||
rm_rf PORTABLE_OUTPUT_DIR if File.exist?(PORTABLE_OUTPUT_DIR) | ||
rm INSTALLER if File.exist?(INSTALLER) | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.