From: Michael D. <mik...@us...> - 2004-12-30 16:55:04
|
Update of /cvsroot/nhibernate/NHibernateContrib/src/NHibernate.Tasks In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv26138/NHibernate.Tasks Added Files: .cvsignore AssemblyInfo.cs Hbm2NetTask.cs NHibernate.Tasks-1.1.csproj NHibernate.Tasks.build Log Message: Moved NHibernate.Tasks and NHibernate.Tool.hbm2net over to the NHibernateContrib module. --- NEW FILE: .cvsignore --- bin obj .#* *.user *.xsx --- NEW FILE: NHibernate.Tasks-1.1.csproj --- <VisualStudioProject> <CSHARP ProjectType = "Local" ProductVersion = "7.10.3077" SchemaVersion = "2.0" ProjectGuid = "{C6F085E3-17FA-424A-9A09-143F3E177FEB}" > <Build> <Settings ApplicationIcon = "" AssemblyKeyContainerName = "" AssemblyName = "NHibernate.Tasks" AssemblyOriginatorKeyFile = "" DefaultClientScript = "JScript" DefaultHTMLPageLayout = "Grid" DefaultTargetSchema = "IE50" DelaySign = "false" OutputType = "Library" PreBuildEvent = "" PostBuildEvent = "" RootNamespace = "NHibernate.Tasks" RunPostBuildEvent = "OnBuildSuccess" StartupObject = "" > <Config Name = "Debug" AllowUnsafeBlocks = "false" BaseAddress = "285212672" CheckForOverflowUnderflow = "false" ConfigurationOverrideFile = "" DefineConstants = "DEBUG;TRACE" DocumentationFile = "" DebugSymbols = "true" FileAlignment = "4096" IncrementalBuild = "false" NoStdLib = "false" NoWarn = "" Optimize = "false" OutputPath = "bin\Debug\" RegisterForComInterop = "false" RemoveIntegerChecks = "false" TreatWarningsAsErrors = "false" WarningLevel = "4" /> <Config Name = "Release" AllowUnsafeBlocks = "false" BaseAddress = "285212672" CheckForOverflowUnderflow = "false" ConfigurationOverrideFile = "" DefineConstants = "TRACE" DocumentationFile = "" DebugSymbols = "false" FileAlignment = "4096" IncrementalBuild = "false" NoStdLib = "false" NoWarn = "" Optimize = "true" OutputPath = "bin\Release\" RegisterForComInterop = "false" RemoveIntegerChecks = "false" TreatWarningsAsErrors = "false" WarningLevel = "4" /> </Settings> <References> <Reference Name = "System" AssemblyName = "System" HintPath = "..\..\..\..\..\..\..\..\WINDOWS\Microsoft.NET\Framework\v1.1.4322\System.dll" /> <Reference Name = "System.Data" AssemblyName = "System.Data" HintPath = "..\..\..\..\..\..\..\..\WINDOWS\Microsoft.NET\Framework\v1.1.4322\System.Data.dll" /> <Reference Name = "System.XML" AssemblyName = "System.Xml" HintPath = "..\..\..\..\..\..\..\..\WINDOWS\Microsoft.NET\Framework\v1.1.4322\System.XML.dll" /> <Reference Name = "log4net" AssemblyName = "log4net" HintPath = "..\..\lib\net\1.1\log4net.dll" /> <Reference Name = "NAnt.Core" AssemblyName = "NAnt.Core" HintPath = "..\..\lib\NAnt.Core.dll" /> <Reference Name = "NHibernate" AssemblyName = "NHibernate" HintPath = "..\..\lib\net\1.1\NHibernate.dll" /> </References> </Build> <Files> <Include> <File RelPath = "AssemblyInfo.cs" SubType = "Code" BuildAction = "Compile" /> <File RelPath = "Hbm2NetTask.cs" SubType = "Code" BuildAction = "Compile" /> <File RelPath = "NHibernate.Tasks.build" BuildAction = "None" /> </Include> </Files> </CSHARP> </VisualStudioProject> --- NEW FILE: AssemblyInfo.cs --- using System.Reflection; using System.Runtime.CompilerServices; //------------------------------------------------------------------------------ // <autogenerated> // This code was generated by a tool. // Runtime Version: 1.1.4322.573 // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. // </autogenerated> //------------------------------------------------------------------------------ [assembly: AssemblyTitleAttribute("NHibernate.Tasks for Microsoft .NET Framework 1.1")] [assembly: AssemblyDescriptionAttribute("NAnt Tasks for NHibernate Tools.")] [assembly: AssemblyCompanyAttribute("nhibernate.sourceforge.net")] [assembly: AssemblyProductAttribute("NHibernate.Tasks")] [assembly: AssemblyCopyrightAttribute("Licensed under LGPL.")] [assembly: AssemblyVersionAttribute("0.5.0.0")] [assembly: AssemblyInformationalVersionAttribute("0.5")] [assembly: AssemblyFileVersionAttribute("0.5.0.0")] [assembly: AssemblyDelaySignAttribute(false)] --- NEW FILE: NHibernate.Tasks.build --- <project name="NHibernate.Tasks" default="build" xmlns="http://nant.sf.net/schemas/nant-0.84.win32.net-1.0.xsd" > <!-- Required properties: * build.dir - (path) root level to build to, assemblies will go in ${build.dir}/bin * build.debug - (true|false) debug build? * current.build.defines - framework-specific build defines * project.version - full project version * project.version.major - the major number of the build * project.version.minor - the minor number of the build * project.version.build - the build number --> <target name="build" description="NAnt Tasks that use NHibernate's Toolset."> <!-- ensure the AssemblyInfo is writable --> <attrib file="AssemblyInfo.cs" readonly="false" /> <asminfo output="AssemblyInfo.cs" language="CSharp"> <imports> <import name="System.Reflection" /> <import name="System.Runtime.CompilerServices" /> </imports> <attributes> <attribute type="AssemblyTitleAttribute" value="${nant.project.name} for ${current.runtime.description}" /> <attribute type="AssemblyDescriptionAttribute" value="NAnt Tasks for NHibernate Tools." /> <attribute type="AssemblyCompanyAttribute" value="nhibernate.sourceforge.net" /> <attribute type="AssemblyProductAttribute" value="${nant.project.name}" /> <attribute type="AssemblyCopyrightAttribute" value="Licensed under LGPL." /> <attribute type="AssemblyVersionAttribute" value="${project.version}" /> <attribute type="AssemblyInformationalVersionAttribute" value="${project.version.major}.${project.version.minor}" /> <attribute type="AssemblyFileVersionAttribute" value="${project.version}" /> <attribute type="AssemblyDelaySignAttribute" value="false" /> </attributes> </asminfo> <csc output="${build.dir}/bin/${nant.project.name}.dll" define="${current.build.defines}" target="library" debug="${build.debug}" doc="${build.dir}/bin/${nant.project.name}.xml" nowarn="1591" > <sources failonempty="true"> <includes name="*.cs" /> </sources> <references basedir="${build.dir}/bin"> <includes name="System.dll" /> <includes name="DotNetMock.dll" /> <includes name="NHibernate.dll" /> <includes name="NAnt.Core.dll" /> <includes name="log4net.dll" /> </references> </csc> </target> </project> --- NEW FILE: Hbm2NetTask.cs --- using System.IO; using System.Text; using NAnt.Core.Attributes; using NAnt.Core.Tasks; using NAnt.Core.Types; namespace NHibernate.Tasks { [TaskName( "hbm2net" )] public class Hbm2NetTask : ExternalProgramBase { private FileSet _set = new FileSet(); private string _output = null; private string _config = null; private string _args = null; [BuildElement( "fileset", Required=true )] public FileSet Hbm2NetFileSet { get { return _set; } set { _set = value; } } [TaskAttribute( "output" )] public string Output { get { return _output; } set { _output = value; } } [TaskAttribute( "config" )] public string Config { get { return _config; } set { _config = value; } } public override string ExeName { get { string asm = this.GetType().Assembly.Location; string basename = asm.Substring( 0, asm.LastIndexOf( Path.DirectorySeparatorChar ) + 1 ); return basename + "NHibernate.Tool.hbm2net.exe"; } } public override string ProgramArguments { get { return _args; } } protected override void ExecuteTask() { StringBuilder sb = new StringBuilder(); if( _output != null ) { sb.Append( "--output=\"" + _output + "\" " ); } if( _config != null ) { sb.Append( "--config=\"" + _config + "\" " ); } foreach( string filename in _set.FileNames ) { sb.Append( "\"" + filename + "\" " ); } _args = sb.ToString(); base.ExecuteTask(); } } } |