Skip to content

Commit

Permalink
Add a .gitignore
Browse files Browse the repository at this point in the history
  • Loading branch information
anaisbetts committed Dec 11, 2012
1 parent e7c9998 commit fb50da1
Show file tree
Hide file tree
Showing 3 changed files with 120 additions and 98 deletions.
22 changes: 22 additions & 0 deletions .gitattributes
@@ -0,0 +1,22 @@
# Auto detect text files and perform LF normalization
* text=auto

# Custom for Visual Studio
*.cs diff=csharp
*.sln merge=union
*.csproj merge=union
*.vbproj merge=union
*.fsproj merge=union
*.dbproj merge=union

# Standard to msysgit
*.doc diff=astextplain
*.DOC diff=astextplain
*.docx diff=astextplain
*.DOCX diff=astextplain
*.dot diff=astextplain
*.DOT diff=astextplain
*.pdf diff=astextplain
*.PDF diff=astextplain
*.rtf diff=astextplain
*.RTF diff=astextplain
72 changes: 36 additions & 36 deletions CONTRIBUTING.md
@@ -1,37 +1,37 @@
## The quick version

1. Open `ReactiveUI_Net4Only.sln` in VS2010 / VS2012
1. Run tests, build ReactiveUI.sln in VS2012 on Win8
1. Submit PR


## How to start hacking on ReactiveUI (the more verbose version)

1. Fork and Clone the source
1. Create a new branch for your feature / bugfix
1. Open the ReactiveUI_Net4Only.sln solution - this is the one you should use unless you're hacking on platform-specific code.
1. Run all the tests, make sure they pass.
1. Write some new tests that fail
1. Make your change
1. See those same tests pass! Hurrah!
1. Build ReactiveUI.sln, see if you broke any other platforms (easy to do, sadly)
1. Push that branch to GitHub (`git push -u origin my-cool-new-feature`)
1. Go to your fork on GitHub, you should see a button with your branch next to it labeled 'Pull Request'
1. Type up some information about your change

## To make a new NuGet release for private use

*This looks hard, but once you get your environment set up, it's really only 'Build in VS, build in Mono, run script'*

1. Put the source into DropBox or another way you can share the same folder between a Mac and a PC (Parallels Shared Folders works too)
1. Edit `**/AssemblyInfo.cs` (i.e. every file named AssemblyInfo.cs) and bump the versions
1. Edit `NuGet/**/*.nuspec` (every nuspec file under the root NuGet folder) and do the same. Make sure to bump the dependent versions too!
1. Open ReactiveUI.sln and build it in Release mode under VS2012 on Windows 8 with the WP8 SDK installed (nothing earlier is supported)
1. Open MonoDevelop, and build ReactiveUI_Mono.sln in Release mode
1. Back on the PC, run `MakeRelease.ps1`
1. You'll end up with two new folders, `Release` and `Nuget-Release`, as well as the `.nupkg` files in the root directory.

## Some quirks

* The only 100% guaranteed .sln files to be maintained are ReactiveUI_Net4Only.sln and ReactiveUI.sln - the others may be missing projects
## The quick version

1. Open `ReactiveUI_Net4Only.sln` in VS2010 / VS2012
1. Run tests, build ReactiveUI.sln in VS2012 on Win8
1. Submit PR


## How to start hacking on ReactiveUI (the more verbose version)

1. Fork and Clone the source
1. Create a new branch for your feature / bugfix
1. Open the ReactiveUI_Net4Only.sln solution - this is the one you should use unless you're hacking on platform-specific code.
1. Run all the tests, make sure they pass.
1. Write some new tests that fail
1. Make your change
1. See those same tests pass! Hurrah!
1. Build ReactiveUI.sln, see if you broke any other platforms (easy to do, sadly)
1. Push that branch to GitHub (`git push -u origin my-cool-new-feature`)
1. Go to your fork on GitHub, you should see a button with your branch next to it labeled 'Pull Request'
1. Type up some information about your change

## To make a new NuGet release for private use

*This looks hard, but once you get your environment set up, it's really only 'Build in VS, build in Mono, run script'*

1. Put the source into DropBox or another way you can share the same folder between a Mac and a PC (Parallels Shared Folders works too)
1. Edit `**/AssemblyInfo.cs` (i.e. every file named AssemblyInfo.cs) and bump the versions
1. Edit `NuGet/**/*.nuspec` (every nuspec file under the root NuGet folder) and do the same. Make sure to bump the dependent versions too!
1. Open ReactiveUI.sln and build it in Release mode under VS2012 on Windows 8 with the WP8 SDK installed (nothing earlier is supported)
1. Open MonoDevelop, and build ReactiveUI_Mono.sln in Release mode
1. Back on the PC, run `MakeRelease.ps1`
1. You'll end up with two new folders, `Release` and `Nuget-Release`, as well as the `.nupkg` files in the root directory.

## Some quirks

* The only 100% guaranteed .sln files to be maintained are ReactiveUI_Net4Only.sln and ReactiveUI.sln - the others may be missing projects
* Please follow my coding convention when submitting PRs - `if` statements have the brackets on the same line, non-public methods shouldBeCasedLikeThis, etc etc. I know I'm weird, Deal With It(tm).
124 changes: 62 additions & 62 deletions MakeRelease.ps1
@@ -1,62 +1,62 @@
$Archs = {"Net40", "Net45", "SL5", "SL4-WindowsPhone71", "WP8", "WinRT45", "Mono"}
$Projects = {"ReactiveUI", "ReactiveUI.Testing", "ReactiveUI.Xaml", "ReactiveUI.Routing", "ReactiveUI.Blend", "ReactiveUI.Cocoa", "ReactiveUI.Gtk", "ReactiveUI.NLog"}

$SlnFileExists = Test-Path ".\ReactiveUI.sln"
if ($SlnFileExists -eq $False) {
echo "*** ERROR: Run this in the project root ***"
exit -1
}

###
### Build the Release directory
###

rmdir -r --force .\Release

foreach-object $Archs | %{mkdir -p ".\Release\$_"}

foreach-object $Archs | %{
$currentArch = $_

foreach-object $Projects | %{cp -r -fo ".\$_\bin\Release\$currentArch\*" ".\Release\$currentArch"}

#ls -r | ?{$_.FullName.Contains("bin\Release\$currentArch") -and $_.Length} | %{echo cp $_.FullName ".\Release\$currentArch"}
}

ls -r .\Release | ?{$_.FullName.Contains("Clousot")} | %{rm $_.FullName}


###
### Build NuGet Packages
###

rm -r -fo .\NuGet-Release. .
cp -r .\NuGet .\NuGet-Release

$libDirs = ls -r .\NuGet-Release | ?{$_.Name -eq "lib"}
$nugetReleaseDir = Resolve-Path ".\NuGet-Release"

foreach ($dir in $libDirs) {
$projName = $dir.FullName.Split("\\")[-2]
$arches = ls $dir.FullName

foreach ($arch in $arches) {
$files = ls $arch.FullName

foreach ($file in $files) {
$src = ".\Release\" + $arch.Name + "\\" + $file.Name
cp -fo $src $file.FullName
}
}
}

$stubs = ls -r -file .\NuGet-Release | ?{$_.Length -eq 0}
if ($stubs.Length -gt 0) {
echo "*** BUILD FAILED ***"
echo ""
echo "*** There are still stubs in the NuGet output, did you fully build? (Hint: Check Silverlight) ***"
#exit 1
}

$specFiles = ls -r .\NuGet-Release | ?{$_.Name.EndsWith(".nuspec")}
$specFiles | %{.\.nuget\NuGet.exe pack $_.FullName}
$Archs = {"Net40", "Net45", "SL5", "SL4-WindowsPhone71", "WP8", "WinRT45", "Mono"}
$Projects = {"ReactiveUI", "ReactiveUI.Testing", "ReactiveUI.Xaml", "ReactiveUI.Routing", "ReactiveUI.Blend", "ReactiveUI.Cocoa", "ReactiveUI.Gtk", "ReactiveUI.NLog"}

$SlnFileExists = Test-Path ".\ReactiveUI.sln"
if ($SlnFileExists -eq $False) {
echo "*** ERROR: Run this in the project root ***"
exit -1
}

###
### Build the Release directory
###

rmdir -r --force .\Release

foreach-object $Archs | %{mkdir -p ".\Release\$_"}

foreach-object $Archs | %{
$currentArch = $_

foreach-object $Projects | %{cp -r -fo ".\$_\bin\Release\$currentArch\*" ".\Release\$currentArch"}

#ls -r | ?{$_.FullName.Contains("bin\Release\$currentArch") -and $_.Length} | %{echo cp $_.FullName ".\Release\$currentArch"}
}

ls -r .\Release | ?{$_.FullName.Contains("Clousot")} | %{rm $_.FullName}


###
### Build NuGet Packages
###

rm -r -fo .\NuGet-Release. .
cp -r .\NuGet .\NuGet-Release

$libDirs = ls -r .\NuGet-Release | ?{$_.Name -eq "lib"}
$nugetReleaseDir = Resolve-Path ".\NuGet-Release"

foreach ($dir in $libDirs) {
$projName = $dir.FullName.Split("\\")[-2]
$arches = ls $dir.FullName

foreach ($arch in $arches) {
$files = ls $arch.FullName

foreach ($file in $files) {
$src = ".\Release\" + $arch.Name + "\\" + $file.Name
cp -fo $src $file.FullName
}
}
}

$stubs = ls -r -file .\NuGet-Release | ?{$_.Length -eq 0}
if ($stubs.Length -gt 0) {
echo "*** BUILD FAILED ***"
echo ""
echo "*** There are still stubs in the NuGet output, did you fully build? (Hint: Check Silverlight) ***"
#exit 1
}

$specFiles = ls -r .\NuGet-Release | ?{$_.Name.EndsWith(".nuspec")}
$specFiles | %{.\.nuget\NuGet.exe pack $_.FullName}

0 comments on commit fb50da1

Please sign in to comment.