XAnalysis is a Visual Studio 2012 Extension, to help you to improve the code quality of your team. Using this tool you can add new analysis scripts, add them to your list, and let your developers to see the problems of theirs codes while they are typing. See http://www.dotnetcup.com for more details. Roslyn is the new language service for Visual Studio 2012 bu it's still CTP. This tool developed using Roslyn CTP version 1.2.20906.2, and needs it on runtime. To make Roslyn available, download and install it. Use /rootsuffix Roslyn parameter when you start Visual Studio 2012.
You can open window using VIEW/Other Windows/XAnalysis. This will open a control window for XAnalysis. This window shows the list of the analysis scripts for which are loaded and active. The server URL is the common site that your team can download scripts. By default I implemented some of the code analysis rules for you and those might be samples while you will write you owns. The default site ishttp://www.dotnetcup.com/AnalysisScripts. Soon I’ll develop a site to share your own scripts with the rest of the world or discuss on them. The next combo contains some commands that can be run. On the result screen you can see the results for your action. For example, if an error occurs while compilation, you can see the error on this window.
How it works: Load = () => The containing class exposes some methods to load you scripts and custom DLLs. To register your scripts you can use Register method. Which has the following signature: Register(string scriptFilename, string code = null, string description = "", bool enabled = true) Example:
RegisterReference(string referencePath) Example: This method will be register your assembly, that you can use in your scripts. For more information about the arguments types you need to see Roslyn web site. As I said it is still CTP, but it already exciting. When I’ll able to open the site dotnetcup.com you will be able to find different scripts there... Your team’s own script site:
Suppressing Message: For some reason you may need to suppress a warning. In this case you can use SuppressMessage attribute for class, method etc. To suppress a message, pass the code value that you provided in Register method, as first parameter to attribute constructor.
You can contact me at dogu.tumerdem@gmail.com. Please send your feedback and consider that it is still CTP and stays CTP until Roslyn will be released.
|