guchenbo / simple-build-tool

Automatically exported from code.google.com/p/simple-build-tool
Other
0 stars 0 forks source link

patching SBT to produce zipped artifacts correctly for all platforms #123

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Hi.

Viktors patch fixes zipped artifacts for mac and linux, this patch makes it 
work with Windows.

Regards,

Ross

Original issue reported on code.google.com by rossaj...@gmail.com on 19 Oct 2010 at 11:25

Attachments:

GoogleCodeExporter commented 9 years ago
This should go into 0.7.5

Original comment by viktor.k...@gmail.com on 20 Oct 2010 at 9:45

GoogleCodeExporter commented 9 years ago
1. why use:

  _.relativePath.replaceAll("([\\\\*])", "/")

instead of:

  _.relativePathString("/")

2. formatting mixes spaces and tabs
3. needs to be split into smaller functions/methods, such as 
makeDirectoryEntry, extractDirectories
4. Make EmptyCRC local to the function

Original comment by dmhar...@gmail.com on 21 Oct 2010 at 1:41

GoogleCodeExporter commented 9 years ago
Updated as per comment 2.  See 0002-123-Comment-2-refactoring-formatting.patch.

Original comment by rossaj...@gmail.com on 22 Oct 2010 at 9:47

Attachments:

GoogleCodeExporter commented 9 years ago
Not sure I understand.  The patch touches every line in the file?

Original comment by dmhar...@gmail.com on 23 Oct 2010 at 1:26

GoogleCodeExporter commented 9 years ago
Hi.

You mentioned the patch mixed spaces and tabs, I was short of time so I ran the 
file through a script to convert tabs to spaces.

find . -name "*.scala" |while read line
do
  expand $line > $line.new
  mv -f $line.new $line
done
echo "converted all tabs to 2 spaces"
exit 0

Original comment by rossaj...@gmail.com on 24 Oct 2010 at 2:31

GoogleCodeExporter commented 9 years ago
You should preserve the original formatting.

Original comment by dmhar...@gmail.com on 25 Oct 2010 at 12:58

GoogleCodeExporter commented 9 years ago
Original formatting preserved.

Original comment by rossaj...@gmail.com on 26 Oct 2010 at 2:25

Attachments:

GoogleCodeExporter commented 9 years ago
modified patch applied, please test:
http://github.com/harrah/xsbt/commit/94c068d2b979c49a

Original comment by dmhar...@gmail.com on 29 Oct 2010 at 3:06

GoogleCodeExporter commented 9 years ago
Tested on Mac and Windows, the zipped artifact looks good.

Original comment by rossaj...@gmail.com on 29 Oct 2010 at 12:18

GoogleCodeExporter commented 9 years ago
Thanks, guys.  With this done, I'll probably get to RC0 this weekend.

Original comment by dmhar...@gmail.com on 29 Oct 2010 at 2:16

GoogleCodeExporter commented 9 years ago
Nice one, looking forward to it.

Original comment by rossaj...@gmail.com on 29 Oct 2010 at 2:26

GoogleCodeExporter commented 9 years ago
Officially went into 0.7.5.RC0.  It should also be in 0.9.x, but you'll still 
want to verify I ported it properly when that comes out.

Original comment by dmhar...@gmail.com on 14 Nov 2010 at 3:34