03 Apr 2009

feedMonologue

Miguel de Icaza: MonoDevelop Support for ASP.NET MVC

Michael Hutchinson blogs about how to use the recently open sourced ASP.NET MVC framework with MonoDevelop. Go from installing MonoDevelop 2.0 to your first ASP.NET MVC application 3 minutes:


There are a few very simple steps:

This will give you basic templates and dialog boxes for solutions, views, controllers and master pages. The code uses Michael's recent implementation of the T4 engine.

Check Michael's Blog for a complete step-by-step setup.

The Add-in bundles Microsoft's recently open sourced ASP.NET MVC engine to run on top of Mono 2.4.

Kudos to Michael that created this add-in in his copious spare time. And kudos to the MonoDevelop team that created such a pleasant platform to extend.

03 Apr 2009 12:00am GMT

02 Apr 2009

feedMonologue

Joseph Hill: ASP.NET MVC on Mono - Two options for the IDE crowd

mvc_referencesSo, you want to get your ASP.NET MVC solution running on Mono? Here are some options:

Visual Studio

Since we?re not shipping ASP.NET MVC with Mono yet, you?ll need to supply your own MVC assembly with your application.

1) From within your MVC project in Visual Studio, find the System.Web.Mvc reference in the solution explorer and open the properties for that assembly.

2) Change the value of the ?Copy Local? property to ?True?. Do *not* set any of the other System.* assemblies to ?Copy Local?.

3) Build your solution

Now, when you copy your compiled ASP.NET MVC project to Linux, you should have everything you need (assuming you installed mono, mono-web, mono-extras, xsp, etc). Want to make sure you have a properly configured install? Download a pre-configured openSUSE 11.1 / Mono 2.4 VMWare image.

To quickly test your solution once you?ve copied the application to Linux, change directories to your project directory, and run xsp2. This will start the xsp development web server running on port 8080, at which point you can browse to your project at http://localhost:8080/ (or whatever the name of your server is)

MonoDevelop 2.0:

Install Michael Hutchinson?s ASP.NET MVC Add-in. This add-in includes the System.Web.Mvc.dll, as well as templates for quickly creating an ASP.NET MVC solution in MonoDevelop.

To quickly test your solution in MonoDevelop, press F5.

02 Apr 2009 9:08pm GMT

Miguel de Icaza: Microsoft releases ASP.NET MVC under the MS-PL License

Microsoft's ASP.NET MVC is an extension built on the core of ASP.NET that brings some of the popular practices and ease of development that were popularized by Ruby on Rails and Django to the .NET developers.

Scott Guthrie ---the inventor of ASP.NET--- just announced that Microsoft is open sourcing the ASP.NET MVC stack under the MS-PL license:

I?m excited today to announce that we are also releasing the ASP.NET MVC source code under the Microsoft Public License (MS-PL). MS-PL is an OSI-approved open source license. The MS-PL contains no platform restrictions and provides broad rights to modify and redistribute the source code. You can read the text of the MS-PL at: http://www.opensource.org/licenses/ms-pl.html

These are incredibly good news. Worth dancing for!

I know that a lot of developers inside Microsoft worked to get this important piece of code released under the MS-PL to ensure that the users of ASP.NET could benefit from the code being open source. I know that at least Phil Haack, Scott Guthrie, Scott Hanselman, Dimitry Robsman and Brian Goldfarb pushed for this.


I am psyched, not only because ASP.NET MVC is usable in Mono and the code is licensed under open source terms, but also because I strongly believe that the same innovation, rapid adoption and experimentation that has happened with the new wave of web stacks will come to ASP.NET MVC across all platforms.

The source code is available for download and we are hoping to integrate this into Mono shortly. Scott Hanselman has a nice blog entry on how ASP.NET MVC went from price-free to open-source free.

In Scott's PDF tutorial he discussed how to build applications with ASP.NET MVC using Visual Studio and how the Rails practices of not repeating yourself and convention over configuration are used by ASP.NET MVC.


We have developed a MonoDevelop add-in that provides a set of templates, dialog boxes and the tooling necessary to take advantage of ASP.NET MVC on Linux and MacOS X as well. Hopefully the experience will be very similar to Visual Studio.

It was only two weeks ago that we were sipping virgin pina coladas at Mix09:


02 Apr 2009 8:39pm GMT

Michael Hutchinson: ASP.NET MVC MonoDevelop Addin Preview

The past month or two, in addition to bugfixing for our recent MonoDevelop 2.0 release, I've been quietly hacking on a MonoDevelop Addin to support writing ASP.NET MVC applications. Those of you following me on Twitter may have picked up a few hints...

Now that Microsoft has released ASP.NET MVC under the MS-Pl licence, I'm making a preview release of the ASP.NET MVC addin for people who'd like to start playing with this exciting new tech on Mono. It's relatively immature, so don't expect everything to work perfectly, but it handles creating and running a VS-compatible ASP.NET MVC project just fine.
<!--break-->
You'll need MonoDevelop 2.0 and Mono 2.4 or later. Make sure you have the package that contains System.Web.Abstractions/Extensions/Routing; on SUSE this is currently mono-extras. The addin includes a copy of the System.Web.Mvc.dll, so you don;t need to do anything special for that.

The addin is in the default MonoDevelop addin repositories (though I may be releasing updated versions from my own repo at http://mjhutchinson.com/mdrepo), so open MonoDevelop, click on the Tools->Add-in Manager menu, and click the Install add-ins... button. Select the ASP.NET MVC addin, and complete the installation.

Installing the ASP.NET MVC Addin

Restart MonoDevelop, as there seems to be a minor issue with reference assemblies updating dynamically.

Now you can create new ASP.NET MVC projects.

Creating a new ASP.NET MVC project

When you create a new project, you'll see a project with all the basics set up, but minimal content, so that you don't have to worry about stripping out things you don't need. If even the "Hello World" view is too much, there's also an "Empty ASP.NET MVC Application" template.

There's an "Add View" command on the context menu for the Views folder, and an "Add Controller" command on the context menu for the Controllers folder.

The Add View Menu

Similarly to the Visual Studio ASP.NET MVC tooling, you can add custom T4 templates for the "Add View" command. As part of developing this feature, I implemented an open-source T4 engine from scratch, which Miguel already blogged about. I also added some syntax highlighting, code folding, and a document outline, and T4 compilation errors are reported in the error pad so you can jump to the error location.

The Add View dialog showing a custom TT template

I'm not happy with the restrictive nature of the ASP.NET MVC T4 host, but initially I went for compatibility with MS' version. In future I'd like a way for these templates to be able to output multiple files and expose additional properties to the GUI, and for the GUI to hide settings that the templates don't support. Note also that the "Strongly Typed" model class option is disabled, as the ASP.NET MVC T4 host exposes a type object for this, whereas MD doesn't load actual types. I'm trying to figure out a way around this.

And the proof that it works with Mono and MD? Hit F5 to build and run.

Running the default Hello World view

There are many more exciting features that I'd like to add, though I have many other things on my plate right now, such as improving MD's Mac support, so contributions are very much welcome.

02 Apr 2009 6:24pm GMT

Jeffrey Stedfast: Building GMime in Visual Studio

Installing the Necessary Dependencies

First, install GNU's iconv library for Windows. You can get a nice msi installer from http://gnuwin32.sourceforge.net/packages/libiconv.htm. Unfortunately, they only offer a Win32 installer, so hopefully that's the platform you intend to target.

Next, you'll want to grab the GLib headers and libraries for Windows. The easiest way to do that is to go to http://www.gtk.org/download.html and download the All-in-One pre-built bundle for Win32. Once downloaded, extract the zip file (the docs suggest not using WinZip due to a bug) and place them wherever you want (I put mine into C:\Users\jeff\Documents).


Configuring Visual Studio

Now that the libiconv and glib headers/libraries are installed, you'll want to configure Visual Studio to know where to find those headers and libraries.

First, go to the Tools menu and select Options...:


In the Options dialog, expand the Projects and Solutions tree item and then select VC++ Directories.

Make sure Win32 is selected in the Platform option menu and then select Executable files under Show directories for:, like so:


Scroll to the bottom of the listbox and add the bin paths for your installed libiconv and Gtk+ bundle just like in the above screenshot.

After you've added the bin paths, you'll need to add the #include paths. Select Include files under Show directories for: and, like you did for the Executable paths you added above, add the paths to the include files.


Next, you'll need to ad the library paths. Under Show directories for:, select Library files and add the appropriate paths to the bottom of the list.


And that's it! You are now ready to start building GMime!

Note: I've been using Microsoft Visual C++ 2008 Express Edition which you can download for free from Microsoft.

02 Apr 2009 8:22am GMT

Jo Shields: Mass infection vector

As part of the great plans for Monobuntu, Canonical Ltd. are sponsoring my attendance at the Ubuntu Developer Summit in Barcelona in May. This will give me a chance to discuss the Desktop team's needs and wants for Mono, bounce suggestions around for how to further shrink the installation footprint, and fling spitballs at the [...]

02 Apr 2009 5:39am GMT

01 Apr 2009

feedMonologue

Joshua Tauberer: Try hacking for government transparency in GSoC

Does the thought of "hacking Congress" entice you? I don't mean breaking in to U.S. Capitol servers, of course, but putting your l33t hacking skillz to use to improve government transparency and civic engagement. The Sunlight Foundation (I have no affiliation) is a mentoring organization in Google Summer of Code 2009. Check it out.

Shameless plug: HackingCongress.org

01 Apr 2009 7:01pm GMT

Francisco Figueiredo: Last activities about Npgsql....

Hi all!

It's been a long time since my last post.

I've been a little bit busy those days (or it's better say: months!) but I'm catching up with Npgsql bugs little by little.

Today I fixed a bug which was making Npgsql to not return the correct number of rows affected by an update when using DataAdapter.Update() method. This bug was floating around for a long time! Thanks Christian for the heads up and testcase!

Some weeks ago, I played with another bug which was causing the famous "stream doesn't support seek operations" exception. It turned out that that the large object api isn't handling errors correctly which is letting data on the stream which causes the problem. I have an ugly workaround for this which is simply flush the stream before trying to write to it again. I sent a message to Npgsql dev list explaining this issue with more details.

That's it for while. I'll be hunting down the remaining bugs and will post progress here.

01 Apr 2009 6:31pm GMT

Andreia Gaita: Google Summer of Code with Mono!

Calling all students!

Google Summer of Code is here, and this is the week where you do your proposals to spend the next few months working on awesome projects on Mono!

Our ideas page is here, and the soc page is here. There is a #monosoc channel on irc.gimpnet.org dedicated to everything Soc, do don't delay, do it now!

01 Apr 2009 6:05pm GMT

Nagappan Alagappan: Announcement: gnome-desktop-testing - New features

Today there was an announcement from Ara

New features in gnome-desktop-testing

* Eitan (eeejay) added a new option to bin/desktop-testing to choose a particular test case to run
* Javier (jcollado) moved constants from gnome_constants.py to gnome.py (gnome_constants.py is now deprecated)
* Ara (ara) changed that report.xsl stylesheet to report also the errors during cleanup(), setupup() or teardown() methods.

These changes are already in the trunk branch of gnome-desktop-testing

01 Apr 2009 2:17pm GMT

David Srbecky: Reminder: Google Summer of Code

The deadline for the Google Summer of Code is 19:00 UTC on April 3rd.

Please submit your applications now.

After you submit the application you still will be able to edit it. So please submit the applications now so that both we and google have some sense of the numbers. If you submit the applications soon, we still might able to give you some feedback that would help you increase your chances of getting accepted.

Here is the wiki page with ideas for SharpDevelop.

01 Apr 2009 10:40am GMT

Codice Software: stackoverflow campaign

We're running a campaign at stackoverflow, displaying the new collection of funny photos we created for the site.

I've just found a screenshot showing one of the ads at a post talking about responsible advertising at stackoverflow:



There're 3 more (plus one considered too sexy, which we'll keep secret for some time :-P) you can find at the site.

01 Apr 2009 4:30am GMT

31 Mar 2009

feedMonologue

Ed Ropple: Setting Up a New libtcod-net Project

After posting my little drooling plug for libtcod-net, the maintainer, Chris, welcomed me to contribute some code. So I did, dumping a 182KB patch in his lap the next day to start refactoring stuff and streamlining the API. So now I guess I should recommend it even more strongly, eh? Read More >>

31 Mar 2009 10:42pm GMT

Eric Butler: Thanks for sending Synapse off to a great start!

I'd like to extend huge thanks to the hundreds and hundreds of people who have showed interested in Synapse these first few weeks. This project is a huge undertaking, and all the support really means a lot.

I've read every tweet and nearly every comment on Reddit, Lifehacker, and other blogs, and the message is clear: the world is ready for better Linux software, and a better instant messenger. People are encouraged by Synapse and looking forward to it's future. No pressure, right?

Huge HUGE thanks to everyone who has reported bugs, helped with troubleshooting/triaging, and shared their feedback in the conference room and on the forums. Synapse is still an alpha product so there have been plenty of problems, and quite frankly I've been a bit overwhelmed :). All the help has been great.

Lots of bugs have already been fixed including better icon support when running under KDE, support for proxy servers, and eliminating many many crashes.

[Screenshot]

The first user-contributed plugin was just merged in, adding preview for wikipedia urls (Thanks goto!):

synapse-wikipedia-1

You can also now add multiple accounts, just note support for this is still a bit rough around the edges.

So what's next? First I'd like to make absolute sure that nobody will find Synapse less useful than other open-source products. In addition to fixing all the open bugs in the tracker, the plan for this week is to focus on implementing two major features:

  1. Logging and a conversation history browser.
  2. Linked Accounts aka transports/gateways. This will make it possible to communicate with friends on other networks, so if you've been holding off on switching to Synapse because most of your friends haven't switched to XMPP yet, hang tight!

I'd also like to add official packages for other distributions very soon, starting with openSUSE and Foresight. If you can help with either of these, please let me know! Big thanks to trontonic for working on ArchLinux support.

There's been great international interest in Synapse as well. So far members of the community have offered to translate Synapse into Russian, French, Italian, Ukrainian, and German… so making Synapse translatable will be a major short-term goal as well.

Once all this low hanging fruit is taken care of, we'll be switching gears back to new innovative features. We've got a few things in mind, and would love to hear your ideas on the forums.

Challenging the status-quo is never easy. If you're looking for a fun and exciting project with tremendous potential to get involved with, I hope you'll consider joining us and help make the vision reality.

31 Mar 2009 6:36pm GMT

Aaron Bockover: Droid Fonts for openSUSE

openSUSE Logo

Just a quick note that I have packaged the Droid fonts from Android for openSUSE. I've submitted the package to Factory so we should have them in 11.2. Droid fonts are freely available from Ascender.

Install 'em now!

Stefano Forenza has some more details on getting the most out of these delicious free fonts. Kudos!

Update: I incorrectly attributed Stefano's post to Neil J Patel, who actually pointed out Stefano's post on Twitter. Twitter is king! So thanks to both Stefano, and Neil for spreading the link :-)

31 Mar 2009 6:31pm GMT

Miguel de Icaza: CoreCLR Security Model

Mono is quickly approaching having a complete implementation of the CoreCLR security model for Mono. This is being developed primarily for use in Moonlight.

This new and simplified security model allows Moonlight to download and execute untrusted code and run it inside a sandbox. A full implementation requires Mono to have an executable image verifier (making sure the binary that we download follows all of the rules and does not try some funny business), an IL verifier that ensures that the code does not contain any unsafe operations and the sandbox system that ensures that the downloaded code only calls methods that it has permission to call.

Click for passable illustration of how the sandbox works.

MSDN has a short introduction to the sandbox and I blogged a long list of links to the original blog entries that documented it.

CoreCLR security can be customized using a handful of attributes. Instead of sprinkling our source code with the attributes and a gazillions #ifdefs we are using our Mono Linker and a few tools and configuration files to reshape our libraries to contain the necessary attributes required to secure the sandbox. We use a number of tools to automate this process and a manual auditing process to audit the results.

This is cool because this is a much simpler sandbox system than CAS ever was and our tools make it very simple for third parties embedding Mono into their applications to create their own sandboxes and reshape what is allowed or not allowed by the sandbox based on their specific needs.

The bad news: this sandbox is only available from trunk right now and will not be easily available until Mono 2.6.

31 Mar 2009 3:13pm GMT