pubxml | Generates public.xml for Android library projects
kandi X-RAY | pubxml Summary
kandi X-RAY | pubxml Summary
Generates public.xml for Android library projects
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of pubxml
pubxml Key Features
pubxml Examples and Code Snippets
Community Discussions
Trending Discussions on pubxml
QUESTION
I am trying to create a release pipeline in Azure DevOps. We already have a functioning build pipeline that works well, it is able to package the build with VSBuild and publish it as an artifact. Then in the release pipeline I am using an IIS Deployment job (which includes IIS Manage and IIS Deploy tasks) and it gets that artifact to deploy.
The problem is that we already have a publish profile (.pubxml) that should take care of pretty much everything the IIS Deployment is doing (at least as far I as I understand it). So to me it seems I have two options that don't require me to refactor the project configuration itself.
- I can try to mimic the settings on the IIS Deployment job to match our .pubxml as closely as possible and manually applying any changes that aren't doable through the task settings. Obviously this is not ideal as that would require us to update both when ever we make changes and it introduces a large chance of the pipeline breaking down over time.
- I can scrap the idea of using IIS Deployment and just use a VSBuild task that uses arguments
/p:DeployOnBuild=true /p:PublishProfile=Staging
. This doesn't seem like best practices because it means my release pipeline isn't passing a build package to deploy, it is just creating a new one at each stage.
So is there a better option that would allow me to utilize the package I created with VSBuild and the .pubxml configuration together in a deploy? If that isn't possible then are either of my options the "correct" way to handle my situation or am I just missing another method of deployment I could use?
Thank you for any help or insight you can provide. Please let me know if there is any more information I can give that would be useful.
...ANSWER
Answered 2021-Mar-16 at 05:53You can try using publish settings file (*.publishsettings
) for your IIS deployment.
A publish settings file (.publishsettings) is different than a publishing profile (.pubxml) created in Visual Studio. A publish settings file is created by IIS or Azure App Service, or it can be manually created, and then it can be imported into Visual Studio.
To view more details, you can see:
QUESTION
What do i need to specify for the root file/folder in publish task for MSBuild "Release"?
Is the .NET release basically the binaries? Because for AngularOutput build I had to specify path of the AngularOutput, but for .NET Release, I am not sure what path that would be, i would think its the entire project, which means...its the binaries?
expected artifact:
UPDATE: Resulting artifact following Kevin's YAML:
inside _PublishedWebsites
Following update3, when running on windows agent:
Update#4: Using VSBuild
...ANSWER
Answered 2021-Mar-29 at 07:11What do i need to specify for the root file/folder in publish task for MSBuild "Release"?
When you use the Msbuild task to build your project, the output file will be saved at the Bin folder by default. For example: $(build.sourcesdirectory)/Projectname/bin
.
Based on the structure of your project, the specific path could be different.
I suggest that you could add msbuild arguments(e.g. /p:OutputPath=$(build.artifactstagingdirectory)
) in the Msbuild task.
For example:
In this case, you could set a specific path as the output path. This will make it easier for you to Archive and Publish artifacts.
Update:
Ubuntu agent:
If I don't set the msbuild arg, the output files will show in the bin folder:
When I add the msbuild arg, it will upload the files to the target path:
They have the same artifacts contents.
Update2:
You could try the following sample to create the package for Azure APP service.
Classic :
Yaml:
QUESTION
I have a .NET 5.0 project, ProjectA
, which depends on a .NET Standard 2.0 project, ProjectB
. I can build and run the .NET 5.0 including its dependency without issues. The two projects are stored in the same root folder, and relying only on default configurations, the resulting libraries end up in
ANSWER
Answered 2021-Mar-19 at 10:02Updating Visual Studio (from 16.8.6 to 16.9.2) fixed the issue, so presumably this was simply a bug in the earlier version of Visual Studio.
QUESTION
I have a .net solution that I can build with msbuild
and successfully generate a deploy package with a PublishProfile.pubxml
transform for deploying to a single web server.
I need to take that build and generate deploy packages for different environments, which are set up as transforms using various .pubxml
profile files.
I know I could build each profile separately, and it'd be negligible risk of injecting a change into a build, but it's time and space that aren't necessary to consume. I would only end up keeping one of them anyway, and just copying the unique web.config
s from each transform into their own deploy package's folder (sorry if this isn't clear, happy to clarify).
I'm looking for something like this pseudocode, which I know is syntactically incorrect but should get the point across:
...ANSWER
Answered 2021-Mar-15 at 20:17I realized I wasn't really asking the right question. When I started searching for msbuild transform posts, I found a way to do what I need.
I landed on updating the .csproj files of the apps I'm building with an AfterBuild
target.
There are 4 transforms required, each with their own .config file as the transform source. I was fortunate that these files had already been created by the application developer.
This is the code I ended up with, placed at the end of the .csproj file, inside the tag. To reduce repetition of paths and filenames, I created
configDir
and xformFile
properties. I like this pattern because it's easily scalable and generic!
QUESTION
Edit
Process Explorer shows seven instances of w3wp with a lock on that file. So I think we need to stop these extra instances.
Since upgrading one project to .NET 5 (the solution has 27 projects in it), we're getting this error when publishing in the post-build event:
The process cannot access the file because it is being used by another process. [D:\somepath\MyProject.csproj]
The post-build event looks like this:
...ANSWER
Answered 2021-Jan-29 at 21:12Stopping and starting the app pool fixed this issue. First, I had to reboot to clear all the w3wp suspended processes. Then I made my post-build events look like this, and things are good.
QUESTION
Some additional context: I created a solution using the Angular project template with ASP.NET Core in Visual Studio 2019. The app has several different environments: DEV, STG, and Production. There are corresponding "appsettings.json" files for the .NET project ("appsettings.DEV.json", "appsettings.STG.json", "appsettings.Production.json"), as well as "environment.ts" files in the "ClientApp" folder ("environment.DEV.ts", "environment.STG.ts", "environment.Production.ts"). This app will be deployed to IIS on a Windows Server, and I have created ".pubxml" publish profiles targeting a folder for each of these environments.
The project template generates the following in the .csproj file:
...ANSWER
Answered 2021-Jan-25 at 15:26I was able to resolve my issue. Here are the changes I made in order to successfully publish the entire .NET 5 & Angular 11 single page app to be deployed to IIS on Windows Server:
Solution configurations for each environment (DEV, STG, and Production) were added:
The ".csproj" file was updated with the following ($(Configuration)
was used instead of $(ASPNETCORE_ENVIRONMENT)
):
QUESTION
I'm trying to deploy a netstandard2.0 class library nuget to a local folder repository (specified in FolderProfile.pubxml). This works fine via VisualStudio's publish context action on a project: the process behind the scenes builds the project and packs desired items according to project.csproj and then copies the nuget package according to FolderProfile.pubxml. I've expected this could be achieved with msbuild as well (to be used in scripts).
...ANSWER
Answered 2021-Jan-14 at 09:24The publish button of VS IDE for class library projects is msbuild -t:pack
rather than msbuild -t:publish
.
On VS IDE, when you click on the Publish button for lib projects, it actually does Pack button to create the nuget packages which reads from the pubxml
file. It is the special feature of VS IDE and caused by the integrated tasks, tools from VS IDE. In other words, it is designed by that.
For different vs projects, Publish Button does different functions.
However, when you use msbuild -t:publish
for lib projects from command line, which gets rid of the VS IDE environment, it does the function like the web projects, windows projects.(put the final output files into the custom publish folder).
So if you want to use commands which does the same function as VS IDE for lib projects, you should abandon the pubxml
file and use this command:
QUESTION
I have been facing this problem with git in which I am trying to upload .mp4
files in a subdirectory of wwwroot/
but whenever I am writing git status
, they won't appear.
The new video files are located inside wwwroot/Content/Videos/ZoomEspecialista/
This problem has never occured before. I have uploaded maybe 10-15 new .mp4
files.
Regardless of that, in my .gitignore
file, I am not excluding the folder which contains these .mp4 files. I have checked multiple times to see if there is something, but I think the problem lies somewhere else. If anyone has any idea on how to tackle this issue, it would be superbly appreciating. Thanks!
The only thing I get from doing a git status is this despite of having uploaded my files to that subdirectory:
EDIT 2: Here is my .gitignore file:
...ANSWER
Answered 2021-Jan-09 at 22:12I'm not sure how big your files are but git normally is not meant to work with very large files. I would suggest enabling lfs for .mp4 files
QUESTION
I tried referring the solution suggested on https://docs.microsoft.com/en-us/aspnet/core/fundamentals/environments?view=aspnetcore-3.1 with the section Set the environment.Also, I added the below part of code in Project file/publish profile
For Windows IIS deployments: Include the property in the publish profile (.pubxml) or project file. This approach sets the environment in web.config when the project is published:
...ANSWER
Answered 2021-Jan-06 at 07:36If you want to use it as environment variable then would suggest to do this
Use below command to set the environment variable in PCF:
QUESTION
I have a Visual studio solution with several projects in it, specifically a DotNet5 asp.net app, that has several netstandard 2.0 references on it. it builds and runs fine in the debugger but continuously throws the metadata errors. It keeps specifically referencing its looking for a net5 folder in the netstandard2 project. I cannot find where its getting this from, the problematic one used to be a multitargeted project against framework 4.7, 4.8, and net5.0, but i got annoyed with the multiple dll's and just migrated it to standard2.0 and had no issues till i want to publish it.
I've tried what a few other questions referenced, cleaning, rebuilding, remove and re add references to other projects, deleted the obj and bin folders out of the solution, the removing the sou file, tried VS 2019 (16.9.0 preview 2) preview vs 2019 (16.8.3) release, different computer (pulled back down from a lan git repository) and got the same error.... also tried searching the entire solution for references to net5.0 and didn't find it outside of the expected locations like the csproj for the asp.net project and its respective pubxml. And just for fun, I temporarily retargeted the library project back to net5.0 and it still threw the same error even when the exact file and path listed did exist.
Using enters for the error below for the different columns in the error message, and removed the "sensitive" info. There is no error code provided by Visual Studio. Anyone else got any more ideas on what to try?
Error
Metadata file 'C:\Users\UserName\source\repos\Solution\Project 2\bin\Release\net5.0\ref\Project 2.dll' could not be found.
Project 1
CSC
0
Edit: adding a couple other sections of the error messages:
...ANSWER
Answered 2021-Jan-04 at 06:48Got it to publish but I am so confused....something to do with the publish profile. If i delete that and generate a new one, works fine. as soon as i edit it using the GUI, broken....generate it again. So far seems ok to edit it manually but TBD. not sure if the "fix" will survive restarting Visual studio or not.
Edit - Scratch that, found the difference. Remove the following line in Properties/FolderProfile.pubxml and it's fine.
net5.0
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install pubxml
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page