locked
Custom Colorable item on Dev11 Exp Hive RRS feed

  • Question

  • I implemented a language service and some custom colorable items under text editor using VS2010 following the way from http://msdn.microsoft.com/en-us/library/bb166250.aspx. It works well on VS2010 and VS2010 Exp Hive.

    Now, I want to port the output into VS2012. I'm using the way mentioned in blog Dissecting VS 2010 Package Registration Your VS Package may not load after porting it to VS 2012 to deploy the package into VS2012. The language service works well and syntex coloring are correct.

    However, I found a strange issue. The colorable configuration items under Tool->Environment->Fonts and Colors-> Text editor are missing in VS2012 Exp Hive but works well in normal VS2012 hive.

    Once I attach a debuger on VS2012, I found when I click Fonts and Colors-> Text editor, VS2012 normal hive is tring to launch my language service dll to get colorable item, but Exp Hive not.

    Does any one have same issue?

    Thanks in advance.

    Yi 

    Sunday, January 6, 2013 9:07 AM

Answers

  • Thanks Ryan for your support.

    I agree with you. But for some purpose, we need to invesigate whether this scenario is workable.

    As you said, we need to apply /rootsuffix to setup the exp hive. Simply apply devenv /setup is not the right direction.

    After applying devenv /setup /rootsuffix exp and devenv /updateConfiguration, our package is deployed successfully. All colorable items are shown under exp hive.

    If you have time could take a look my another issue: http://social.msdn.microsoft.com/Forums/en-US/vsx/thread/305c05ac-059b-4772-8ba4-fc9bed905ced/, it talks about some name of VS defined colorable item are changed from VS2010 to VS2012.

    Thanks again.

    Regards,

    Yi  


    • Edited by Li Yifeng Tuesday, January 8, 2013 5:43 AM typo
    • Marked as answer by Li Yifeng Monday, January 14, 2013 2:21 AM
    Tuesday, January 8, 2013 5:42 AM

All replies

  • The experimental hive is only launched when you do F5 from a package project or if you explicitly specify it. The blog you cite indicates how one would get an extension installed in the normal VS instance, I believe you would need to manually deploy your extension to the proper location to get it to run in the experimental instance (i.e. it pulls extensions from a different location than your primary VS instance, otherwise there would be no point in having it).

    If you upgrade your project you may have to manually change your debug target to launch 2012 because if the project was from 2010 it will try to launch 2010.


    Sunday, January 6, 2013 6:08 PM
  • Thanks Ryan.

    According to the following statement in  Dissecting VS 2010 Package Registration,

    In summary, if you want to manually add a package to run under the experimental shell environment (when launching devenv.exe with ‘/rootsuffix Exp’), you will need to do the following:

    1. Copy your package assembly to a subdirectory under …<user>\AppData\Local\Microsoft\VisualStudio\10.0Exp\Extensions
    2. Create and copy a pkgdef and vsixmanifest to the same directory
    3. Launch devenv with ‘/rootsuffix Exp’ command line switch
    4. Enable the package via the ‘Tools.Extension Manager’

    We are also able to deploy a package to VS2012 Exp hive using above workaround. There is no deploy problem on my side.

    My package is deployed successfuly in VS2012Exp Hive, it is recoginized and can be enable under extension manager of VS2012 exp hive. Most of feature of my package works well, like syntax coloring. If I attached a debugger, the break point of my package can be hit during using my language service under VS2012 exp hive.  

    However, the colorable configuration items under Tool->Environment->Fonts and Colors-> Text editor are missing in exp hive only. If I use above way to register my package to normal hive, every thing goes well.

    It does really not make sence to me. Could you help double check this issue?

    Thanks a lot

    Regards,

    Yi

    Monday, January 7, 2013 2:12 AM
  • Hi Ryan,

    Any update?

    Thanks,

    Adolf

    Tuesday, January 8, 2013 1:34 AM
  • Hi Adolf,

    Are you get same issue with me?

    Yi

    Tuesday, January 8, 2013 2:08 AM
  • Hi Ryan,

    If I use /updateConfiguration (You mention in http://social.msdn.microsoft.com/Forums/en-US/vsx/thread/46806e9b-c114-42c3-98ff-d9717a9dd02f/) to deploy the package rather than /Setup for VS2012 Exp Hive, my colorable items start to be shown in  Tool->Environment->Font and Color->Text Editor.

    Could you take a look for this issue and let me know why a stronger /Setup will lead the colorable item missing?

    Thanks in advance.

    Regards,

    Yi

    Tuesday, January 8, 2013 2:26 AM
  • Did you run /setup with /Rootsuffix Exp? /Setup modifes the registry, if you don't specify /Rootsuffix Exp it will modify the regular (non-experimental instance) registry.

    Tuesday, January 8, 2013 3:53 AM
  • According to Your VS Package may not load after porting it to VS 2012, I need to run /setup without /Rootsuffix Exp.

    If I run with /Rootsuffix Exp, the package will not be shown under exp hive.

    After runing /updateconfiguration, it make my colorable item shown under tool options. However, after I uninstall the package, reset the exp hive, re-deploy it again, it doesn't work again. It really confused me.


    • Edited by Li Yifeng Tuesday, January 8, 2013 4:00 AM
    Tuesday, January 8, 2013 3:58 AM
  • Where does it say to run setup without /rootsuffix in that post? I don't see that. Also that link does not talk about your scenario, deploying to the experimental hive != deploying to the normal location. There are likely no instructions for what you are trying to do because it is not a normal scenario. Most people deploy to the experimental instance ONLY for the VS they are developing on, testing/deployment on other version are deployed to the regular instance. I don't know why what you are trying is not working, but it isn't a scenario that we likely test/support, so it wouldn't surprise me if there were bugs.

    Ryan

    Tuesday, January 8, 2013 4:08 AM
  • Thanks Ryan for your support.

    I agree with you. But for some purpose, we need to invesigate whether this scenario is workable.

    As you said, we need to apply /rootsuffix to setup the exp hive. Simply apply devenv /setup is not the right direction.

    After applying devenv /setup /rootsuffix exp and devenv /updateConfiguration, our package is deployed successfully. All colorable items are shown under exp hive.

    If you have time could take a look my another issue: http://social.msdn.microsoft.com/Forums/en-US/vsx/thread/305c05ac-059b-4772-8ba4-fc9bed905ced/, it talks about some name of VS defined colorable item are changed from VS2010 to VS2012.

    Thanks again.

    Regards,

    Yi  


    • Edited by Li Yifeng Tuesday, January 8, 2013 5:43 AM typo
    • Marked as answer by Li Yifeng Monday, January 14, 2013 2:21 AM
    Tuesday, January 8, 2013 5:42 AM
  • I'd suspect udpateConfiguration may also need /rootsuffix Exp, basically anything that changes the registry, and this applies to both /setup and /updateConfiguration, would need to know they should be using a non-default registry root (i.e. rootSuffix Exp tells them to use <vs reg root>_Exp for all of their modifications, which is the registry root that the Experimental Instance runs off).

    Ryan

    Tuesday, January 8, 2013 6:07 AM
  • Basicly, I got your idea. 

    However, if i just call /updateConfiguration /rootsuffix exp, the package will not be deployed. The package will be shown in Exp hive only after we call /setup or /updateConfiguration.

    Yi

    Tuesday, January 8, 2013 6:38 AM