include tmLanguage does not work correctly in Visual Studio - ansible

As you can see in Visual Studio Ansible Extension Project we have tmLanguage for Ansible grammar that include other tmLanguages as you can see below
<dict>
<key>include</key>
<string>injection.ansible.jinja-conditionals</string>
</dict>
But syntax highlighting does not work correctly, the output like below

Related

Visual Studio for Mac Version 17.3 Preview debugger problem on physical device

Using, Visual Studio for Mac Version 17.3 Preview I get debugger problem on physical device and can't run my Xamarin app on my iPhone
It says:
warning MT1043: Failed to launch the application using the instruments service. Will try launching the app using gdb service.
Launching 'com.myapplicaion.applicationname' on the device 'Leos iPhone'
Could not find the application 'com.myapplicaion.applicationname' on the device 'My iPhone'.
It could be related to the problem with Visual Studio (Windows): Visual Studio 2022 17.2 and 17.3 cannot start debugger
Emulator works
Anyone know how I could get it to work?
Blank Xamarin.Forms project works
A new stable version was released with the problem: Version 17.0.3 (build 21), I shifted to it
I will move all files and install all Nuget packages into the new blank Xamarin.Forms project
The only hint I found was a difference in *.csproj forms file:
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<DebugType>portable</DebugType>
<DebugSymbols>true</DebugSymbols>
</PropertyGroup>
... which was missing in my project and present in the newly created project. It did not help to add it though
I found the the cause to be the Entitlements.plist. When I have it empty - the debugger works. However I need entitlements...
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>com.apple.developer.icloud-services</key>
<array>
<string>CloudKit</string>
</array>
<key>com.apple.developer.icloud-container-identifiers</key>
<array>
<string>iCloud.company.container</string>
</array>
</dict>
</plist>
I updated Xcode. Opened Visual Studio and it kept crashing, My Mac could not open other programs with Visual Studio open. I could not force quit Visual Studio.
It was stuck Restoring packages.
It said I should install version command line control: sudo xcode-select --install. Executing it said it already was installed
When verified 13.4.1 Xcode version and installing additional components. Visual Studio could be opened and run properly again.
But Im back to the original issue that debugger won't connect

How to setup SDL2/SDL.h in visual studio?

I tried to setup SDL 2 in visual studio following similar instruction to tutorial and the result was that visual studio was recognizing SDL.h but it was not recognizing SDL2/SDL.h and the include folder of sld2 development tools (link) does not have any SDL2/SDL.h file. How to setup SDL2/SDL.h in visual studio ?
Actually SDL2 in SDL2/SDL.h is a folder.It is a folder that keeps SDL.h in the directory the compiler looks #include directives in.Change that include folder name to SDL2.

Visual Studio Pre-Build Variables (TextTransform.exe)

I need to use TextTransform and I have currently this pre-build Event, which it's working:
"%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\TextTransform.exe" -a !!BuildConfiguration!$(Configuration) "$(ProjectDir)Properties\AssemblyInfo.tt"
But I wanted to replace the \2019\Enterprise\ with variables according to the user version/edition, tried to google and search here but didn't found anything.
Found a solution, in this link have some really useful varaibles:
Link to all Visual Studio $ variables
Then I'm using:
MSBuildStartupDirectory
Which is:
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE
Result:
"$(MSBuildStartupDirectory)\TextTransform.exe" -a !!BuildConfiguration!$(Configuration) "$(ProjectDir)Properties\AssemblyInfo.tt"

Any Way to install/import sublime/vscode color theme for visual studio 2015?

I am actually trying to get one color theme that I use in VS-Code for VS2015. But the theme is for sublime-text/atom. I can't find that color-theme for visual studio 2015.
I found this question here
visual studio 2015 sublime theme
Is there any way to install or import vs-code extension to visual studio 2015 ?
There are currently no ways to convert between the two theme formats. Visual Studio uses a proprietary theme style as shown here, whereas Visual Studio Code uses textmate themes as shown here
Visual Studio Format:
<Color Name="CSS String Value">
<Background Type="CT_AUTOMATIC" Source="00000000" />
<Foreground Type="CT_RAW" Source="FFD69D85" />
</Color>
<Color Name="HTML Attribute">
<Background Type="CT_AUTOMATIC" Source="00000000" />
<Foreground Type="CT_RAW" Source="FF9CDCFE" />
</Color>
Visual Studio Code
<dict>
<key>name</key>
<string>Tag Inline Source</string>
<key>scope</key>
<string>meta.tag.inline source, text.html.php.source</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string>
</string>
<key>foreground</key>
<string>#9AA83A</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Tag Other</string>
<key>scope</key>
<string>meta.tag.other, entity.name.tag.style, entity.name.tag.script, meta.tag.block.script, source.js.embedded punctuation.definition.tag.html, source.css.embedded punctuation.definition.tag.html</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string>
</string>
<key>foreground</key>
<string>#9872A2</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Tag Attribute</string>
<key>scope</key>
<string>entity.other.attribute-name, meta.tag punctuation.definition.string</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string>
</string>
<key>foreground</key>
<string>#D0B344</string>
</dict>
</dict>
As you can see, they are very different formats, and unfortunately there aren't tools for converting between them.
If you have a Textmate .tmtheme file, like the ones used for themes in Sublime Text, then you can convert that to a VSCode theme extension using the yo code tool as described in the documentation: https://vscode-docs.readthedocs.io/en/stable/customization/themes/#adding-a-new-theme
Basically, you need npm installed.
Place the .tmtheme file somewhere accessible from your terminal and do:
npm install -g yo generator-code
yo code
Follow the prompts, specifying the full file path of the theme file.
Place the resulting extension folder into %vs_code_dir%/extensions/ and restart VSCode before using your new theme.

Visual Studio Code: How to change color of '->' and '.' operators in C?

I'm trying out VS Code, but I would like to use my Sublime color settings. I've used the 'yo code' tool as suggested by the installation instructions to import the settings as TextMate. This worked mostly, however I cannot figure out how to change the syntax of the indirection operators '->' and '.' in the C language.
I assume it should be in the field here:
<dict>
<key>name</key>
<string>keyword.operator</string>
<key>scope</key>
<string>keyword.operator</string>
<key>settings</key>
<dict>
<key>foreground</key>
<string>#aaaaaa</string>
</dict>
</dict>
Here is an example screenshot of the differences:
Sublime:
VS Code:

Resources