Can't add images to a vscode Extension readme.md - visual-studio-code

The error
Every time I try to compile the extension with the images inside of the readme.md it returns the following error:
> vsce package
Executing prepublish script 'npm run vscode:prepublish'...
> waiter#0.0.1 vscode:prepublish D:\projetos\waiter
> npm run package
> waiter#0.0.1 package D:\projetos\waiter
> webpack --mode production --devtool hidden-source-map
[webpack-cli] Compiler starting... [webpack-cli] Compiler is using config: 'D:\projetos\waiter\webpack.config.js'
[webpack-cli] Compiler finished
asset extension.js 1.18 KiB [compared for emit] [minimized] (name: main) 1 related asset
./src/extension.ts 2.15 KiB [built] [code generated]
external "vscode" 42 bytes [built] [code generated]
webpack 5.62.2 compiled successfully in 1625 ms
ERROR Couldn't detect the repository where this extension is published. The image './readmeImages/initializing.gif' will be broken in README.md. GitHub/GitLab repositories will be automatically detected. Otherwise, please provide the repository URL in package.json or use the --baseContentUrl and --baseImagesUrl options.
It recomends me to run with --baseContentUrl and --baseImagesUrl
> vsce package --baseContentUrl --baseImageUrl
Executing prepublish script 'npm run vscode:prepublish'...
> waiter#0.0.1 vscode:prepublish D:\projetos\waiter
> npm run package
> waiter#0.0.1 package D:\projetos\waiter
> webpack --mode production --devtool hidden-source-map
[webpack-cli] Compiler starting...
[webpack-cli] Compiler is using config: 'D:\projetos\waiter\webpack.config.js'
[webpack-cli] Compiler finished
asset extension.js 1.18 KiB [compared for emit] [minimized] (name: main) 1 related asset
./src/extension.ts 2.15 KiB [built] [code generated]
external "vscode" 42 bytes [built] [code generated]
webpack 5.62.2 compiled successfully in 1628 ms
ERROR Invalid URL: --baseImageUrl/readmeImages/initializing.gif
Readme.md
## Features
The gif can show you what I'm talking about, you just open the folder and everything is setup for your development session
<img src="https://github.com/biel-correa/waiter/tree/master/readmeImages/initializing.gif?raw=true" alt="initializing a project">
## Requirements
The Waiter needs a JSON file so that he knows what you want, but don't worry as soon as it runs he'll ask you to create it.
<img src="https://github.com/biel-correa/waiter/blob/master/readmeImages/askingToCreate.png?raw=true" alt="how it asks to create">
view repository

I had to open the github markdown editor so that I could drag and drop the files I wanted to show, when you do like that github generates a custom path for the file.
My link
https://github.com/biel-correa/waiter/tree/master/readmeImages/initializing.gif
Generated link
https://user-images.githubusercontent.com/56176344/143320917-12fe3516-36af-4ec5-a073-5c2dd9abdc46.gif

Related

Module not found - polyfill

BREAKING CHANGE: webpack < 5 used to include polyfills for node.js core modules by default.
[ng] This is no longer the case. Verify if you need this module and configure a polyfill for it.
[ng]
[ng] If you want to include a polyfill, you need to:
[ng] - add a fallback 'resolve.fallback: { "https": require.resolve("https-browserify") }'
installed
npm install --save-dev crypto-browserify stream-browserify assert stream-http https-browserify os-browserify url buffer process
still same error occurs

NuGet package problems while building DirectX Graphics Samples

I've encountered NuGet problems while building DirectX-Graphics-Samples
The error occurs with many projects, here is an example:
NuGet Package restore failed for project D3D12Multithreading: Unable to find version '1.0.161208001' of package 'WinPixEventRuntime'. C:\Program Files (x86)\Microsoft SDKs\NuGetPackages\: Package 'WinPixEventRuntime.1.0.161208001' is not found on source 'C:\Program Files (x86)\Microsoft SDKs\NuGetPackages\'. . Please see Error List window for detailed warnings and errors. 1>------ Build started: Project: D3D12Multithreading, Configuration: Debug x64 ------ 1>D:\Personal\Projects\MyProjects\ProjDirectXGraphicsSamples\Samples\Desktop\D3D12Multithreading\src\D3D12Multithreading.vcxproj(157,5): error : This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is D:\Personal\Projects\MyProjects\ProjDirectXGraphicsSamples\Samples\Desktop\D3D12Multithreading\src\packages\WinPixEventRuntime.1.0.161208001\build\WinPixEventRuntime.targets. 1>Done building project "D3D12Multithreading.vcxproj" -- FAILED.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
Microsoft's suggestions for restoring packages
did not help either:
NuGet Package restore failed for project D3D12Multithreading: Unable to find version '1.0.161208001' of package 'WinPixEventRuntime'.
C:\Program Files (x86)\Microsoft SDKs\NuGetPackages\: Package 'WinPixEventRuntime.1.0.161208001' is not found on source 'C:\Program Files (x86)\Microsoft SDKs\NuGetPackages\'.
. Please see Error List window for detailed warnings and errors.
NuGet package restore finished.
Time Elapsed: 00:00:00.0389909
========== Finished ==========
I am using VS Enterprise 2019(16.5.1), .NET 4.8.03752, SDK 10.0.19041.0.
I have NuGet package manager in my VS configuration but not NuGet targets and build tasks.
Here is my .vsconfig
{
"version": "1.0",
"components": [
"Microsoft.VisualStudio.Component.CoreEditor",
"Microsoft.VisualStudio.Workload.CoreEditor",
"Microsoft.NetCore.Component.Runtime.3.1",
"Microsoft.NetCore.Component.SDK",
"Microsoft.VisualStudio.Component.NuGet",
"Microsoft.VisualStudio.Component.Roslyn.Compiler",
"Microsoft.VisualStudio.Component.Roslyn.LanguageServices",
"Microsoft.VisualStudio.ComponentGroup.WebToolsExtensions",
"Microsoft.VisualStudio.Component.TypeScript.3.8",
"Microsoft.VisualStudio.Component.JavaScript.TypeScript",
"Microsoft.Component.MSBuild",
"Microsoft.VisualStudio.Component.TextTemplating",
"Microsoft.VisualStudio.Component.SQL.LocalDB.Runtime",
"Microsoft.VisualStudio.Component.Common.Azure.Tools",
"Microsoft.VisualStudio.Component.SQL.CLR",
"Microsoft.Net.Component.4.5.TargetingPack",
"Microsoft.VisualStudio.Component.IntelliCode",
"Microsoft.VisualStudio.Component.IntelliTrace.FrontEnd",
"Microsoft.VisualStudio.Component.DiagnosticTools",
"Microsoft.VisualStudio.Component.AppInsights.Tools",
"Microsoft.VisualStudio.Component.WebDeploy",
"Microsoft.Net.Component.4.7.1.TargetingPack",
"Microsoft.VisualStudio.Component.ClassDesigner",
"Microsoft.VisualStudio.Component.GraphDocument",
"Microsoft.VisualStudio.Component.CodeMap",
"Microsoft.Component.PythonTools",
"Microsoft.Component.PythonTools.Miniconda",
"Microsoft.Component.PythonTools.Web",
"Microsoft.VisualStudio.Component.VC.CoreIde",
"Microsoft.VisualStudio.Component.Windows10SDK",
"Microsoft.VisualStudio.Component.VC.Tools.x86.x64",
"Microsoft.VisualStudio.Component.Graphics.Tools",
"Microsoft.VisualStudio.Component.VC.DiagnosticTools",
"Microsoft.VisualStudio.Component.Windows10SDK.18362",
"Component.CPython3.x64",
"Microsoft.VisualStudio.Workload.Python",
"Microsoft.ComponentGroup.Blend",
"Microsoft.VisualStudio.Component.Debugger.JustInTime",
"Microsoft.VisualStudio.ComponentGroup.MSIX.Packaging",
"Microsoft.VisualStudio.Component.VC.Redist.14.Latest",
"Microsoft.VisualStudio.ComponentGroup.ArchitectureTools.Native",
"Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Core",
"Microsoft.VisualStudio.ComponentGroup.WebToolsExtensions.CMake",
"Microsoft.VisualStudio.Component.VC.CMake.Project",
"Microsoft.VisualStudio.Component.VC.ATL",
"Microsoft.VisualStudio.Component.VC.TestAdapterForBoostTest",
"Microsoft.VisualStudio.Component.VC.TestAdapterForGoogleTest",
"Microsoft.VisualStudio.Component.VC.ASAN",
"Microsoft.VisualStudio.Component.VC.Llvm.ClangToolset",
"Microsoft.VisualStudio.Component.VC.Llvm.Clang",
"Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Llvm.Clang",
"Microsoft.VisualStudio.Workload.NativeDesktop",
"Microsoft.Component.NetFX.Native",
"Microsoft.VisualStudio.ComponentGroup.UWP.NetCoreAndStandard",
"Microsoft.VisualStudio.Component.Graphics",
"Microsoft.VisualStudio.ComponentGroup.UWP.Xamarin",
"Microsoft.VisualStudio.ComponentGroup.UWP.Support",
"Microsoft.VisualStudio.Workload.Universal",
"Microsoft.Net.Component.3.5.DeveloperTools",
"Microsoft.VisualStudio.Component.Unity",
"Component.UnityEngine.x64",
"Component.UnityEngine.x86",
"Microsoft.VisualStudio.Workload.ManagedGame",
"Microsoft.VisualStudio.Workload.NativeGame",
"Component.MDD.Linux",
"Component.Linux.CMake",
"Microsoft.VisualStudio.Workload.NativeCrossPlat"
]
}
What components should be in my VS installation for NuGet to work properly?
The project use package.config file to manage nuget packages.
So try to modify the Package Reference to Package.config
All I had to do was to add https://api.nuget.org/v3/index.json as the source of nuget.org in Visual Studio Tools->Options->NuGet Package manager

Too long path exception raised to a specific version of a package

I built my private Nuget repository on Azure free app service.
And I added the url into Visual Studio 2015.
There is a package having three versions 1.0.3~1.0.5.
The problem is only 1.0.3 version of the package will be successfully installed.
Others are always failed due to the exception (Too long path or file name).
I don't know why they show me different results.
Non of settings are different.
Also I placed the project folder on the root of D: drive.
Please see the log and let me know the reason :D
Attempting to gather dependency information for package 'GEPAEntities.1.0.5' with respect to project 'TestApps\EntitiesTestConsole', targeting '.NETFramework,Version=v4.0'
Gathering dependency information took 52.53 ms
Attempting to resolve dependencies for package 'GEPAEntities.1.0.5' with DependencyBehavior 'Lowest'
Resolving dependency information took 0 ms
Resolving actions to install package 'GEPAEntities.1.0.5'
Resolved actions to install package 'GEPAEntities.1.0.5'
Retrieving package 'GEPAEntities 1.0.5' from 'P-ful, Inc.'.
GET http://pfulnugetserver.azurewebsites.net/api/v2/package/gepaentities/1.0.5
OK http://pfulnugetserver.azurewebsites.net/api/v2/package/gepaentities/1.0.5 63ms
Installing GEPAEntities 1.0.5.
Error downloading 'GEPAEntities.1.0.5' from 'http://pfulnugetserver.azurewebsites.net/api/v2/package/gepaentities/1.0.5'.
The specified path, file name, or both are too long. The fully qualified file name must be less than 260 characters, and the directory name must be less than 248 characters.
Install failed. Rolling back...
Package 'GEPAEntities.1.0.5' does not exist in project 'EntitiesTestConsole'
Package 'GEPAEntities.1.0.5' does not exist in folder 'D:\GEPAClient\packages'
Executing nuget actions took 803.27 ms
Error downloading 'GEPAEntities.1.0.5' from 'http://pfulnugetserver.azurewebsites.net/api/v2/package/gepaentities/1.0.5'.
The specified path, file name, or both are too long. The fully qualified file name must be less than 260 characters, and the directory name must be less than 248 characters.
========== Finished ==========
Time Elapsed: 00:00:03.2133955
I am not sure, but I resolved my problem.
I just added supported framework versions into nuspec file.
<dependencies>
<group targetFramework=".NETFramework4.5" >
...
</group>
<group targetFramework=".NETFramework4.0" >
...
</group>
</dependencies>
Anyway it is working that I expected.

How can I deploy updates to an OpenShift Mono application with Jenkins?

I created a mono application on OpenShift using the community cartridge here.
Now, I'm reading about how to set up continuous builds via jenkins here.
The default mono application doesn't seem to come with any of the necessary scripts for building, restoring NuGet packages, etc. Instead, the git repo seems to have the DLL binaries in it, which doesn't seem sustainable.
What's the best approach for deploying mono on open shift?
I will refine this answer when/if I get it working...
Did you start by clicking the "Continuous Integration - Enable Jenkins" link below your cartridge on your OpenShift Applications page?
Once I did this, my git push output changed from:
remote: CLIENT_MESSAGE: Stopping Apache+mod_mono HTTPD server
remote: Waiting for stop to finish
remote: Waiting for stop to finish
remote: Stopping Postgres cartridge
remote: Building git ref 'master', commit 8da79f2
remote: Preparing build for deployment
remote: Deployment id is 05e8d1d8
remote: Activating deployment
remote: Starting Postgres cartridge
remote: Postgres started
remote: CLIENT_MESSAGE: Starting Apache+mod_mono HTTPD server
remote: -------------------------
remote: Git Post-Receive Result: success
remote: Activation status: success
remote: Deployment completed with status: success
To:
remote: Executing Jenkins build.
remote:
remote: You can track your build at https://jenkins-[you].rhcloud.com/job/mono-build
remote:
remote: Waiting for build to schedule...........Done
remote: Waiting for job to complete...............Done
remote: SUCCESS
remote: New build has been deployed.
remote: -------------------------
remote: Git Post-Receive Result: success
remote: Deployment completed with status: success
But if I remove the bin directory from my source code, then the web site no longer works, even though the build "succeeds." So clearly it is only just blindly copying the files out of git.
So next I did a Update-Package -reinstall -ProjectName OpenShift in the Package Manager console, then right-clicked on the solution and chose "Enable NuGet package restore," and committed/pushed those changes.
In the Jeninks manager I went to Configure the build and added xbuild OpenShift.sln after the gear build line in the "Execute shell" area.
Now it actually tries to do a real build, which fails with the error:
+ xbuild OpenShift.sln
XBuild Engine Version 3.0.7.0
Mono, Version 3.0.7.0
Copyright (C) Marek Sieradzki 2005-2008, Novell 2008-2011.
Build started 01/13/2015 20:56:29.
__________________________________________________
/var/lib/openshift/[my ID]/app-root/runtime/repo/OpenShift.sln: warning : /var/lib/openshift/[my ID]/app-root/runtime/repo/OpenShift.csproj: /var/lib/openshift/[my ID]/mono/mono/lib/mono/xbuild/Microsoft/VisualStudio/v10.0/WebApplications/Microsoft.WebApplication.targets: Project file could not be imported, it was being imported by /var/lib/openshift/[my ID]/app-root/runtime/repo/OpenShift.csproj: Access to the path "/var" is denied.
Project "/var/lib/openshift/[my ID]/app-root/runtime/repo/OpenShift.sln" (default target(s)):
Target ValidateSolutionConfiguration:
Building solution configuration "Debug|Any CPU".
Target Build:
/var/lib/openshift/[my ID]/app-root/runtime/repo/OpenShift.csproj: error : /var/lib/openshift/[my ID]/app-root/runtime/repo/OpenShift.csproj: /var/lib/openshift/[my ID]/mono/mono/lib/mono/xbuild/Microsoft/VisualStudio/v10.0/WebApplications/Microsoft.WebApplication.targets: Project file could not be imported, it was being imported by /var/lib/openshift/[my ID]/app-root/runtime/repo/OpenShift.csproj: Access to the path "/var" is denied.
Task "MSBuild" execution -- FAILED
Done building target "Build" in project "/var/lib/openshift/[my ID]/app-root/runtime/repo/OpenShift.sln".-- FAILED
Done building project "/var/lib/openshift/[my ID]/app-root/runtime/repo/OpenShift.sln".-- FAILED
Build FAILED.
Looks like it might be this problem so I made the following manual diff to OpenShift.csproj:
- <Import Project="$(VSToolsPath)\WebApplications\Microsoft.WebApplication.targets" Condition="'$(VSToolsPath)' != ''" />
- <Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v10.0\WebApplications\Microsoft.WebApplication.targets" Condition="false" />
+ <Import Project="$(SolutionDir)\MSBuild\Microsoft\VisualStudio\v12.0\WebApplications\Microsoft.WebApplication.targets" />
and copied from Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\WebApplications into the above path in my local project.
After committing/pushing that, now I get this new build error:
Project "/var/lib/openshift/[my id]/app-root/runtime/repo/OpenShift.sln" (default target(s)):
Target ValidateSolutionConfiguration:
Building solution configuration "Debug|Any CPU".
Target Build:
Project "/var/lib/openshift/54b5dc8efcf933bb7300001f/app-root/runtime/repo/OpenShift.csproj" (default target(s)):
Target RestorePackages:
Executing: mono --runtime=v4.0.30319 "/var/lib/openshift/[my id]/app-root/runtime/repo/.nuget/NuGet.exe" install "/var/lib/openshift/[my id]/app-root/runtime/repo/packages.config" -source "" -RequireConsent -solutionDir "/var/lib/openshift/[my id]/app-root/runtime/repo/"
Cannot open assembly '/var/lib/openshift/[my id]/app-root/runtime/repo/.nuget/NuGet.exe': File does not contain a valid CIL image.
Looks like there's a problem running NuGet.exe - Might be this

scons build in eclipse

I have converted a static library project and an exe project to Scons project in ECLIPSE. These were building fine by Makefile.
But when I am building the static library project it gives an error as below -
=== Running SCons at 18/11/13 8:55 PM ====
Command line: /usr/bin/scons -u --jobs=8
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
scons: building associated VariantDir targets: Debug
o Debug/add.o -c add.cpp
sh: o: not found
ar rc Debug/libadd.a Debug/add.o
ar: Debug/add.o: No such file or directory
scons: *** [Debug/libadd.a] Error 1
scons: building terminated because of errors.
Duration 301 ms.
1) my main objective is to a trigger a build once somehow (in the exe project) and both the project will be compiled in ECLIPSE. Is there a way to see and edit a SConscript in eclipse.
2) How do I do it? By manually writing SConscript and SConstruct file? :(
It looks from the SCons output like SCons can't find the compiler on your system. What OS are you using? And what version of SCons? (Type scons --version to see that.)