-
Notifications
You must be signed in to change notification settings - Fork 287
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Installed sample project's "Data" / content files show up in VS #845
Comments
Yes I noticed this before. The fact that they are editable seems to be some issue with the tooling as it should be readonly. Nothing we can do about that iam afraid. As I don't think this is very pretty I think we should find a way to hide these files. They should still be included in the project though else they won't get copied to the output. |
Well seems you are not allowed to change any properties of contentfiles so I don't currently see a way to solve this. |
I think this is more a issue with visual studio handling of contentfiles in the solution explorer. Microsoft has chosen to dump everything in the root which is not very clear. It would be much clearer if it was listed under Dependencies under the respective package. So I think we should make a issue about this (not sure which repo houses visual studio related issues) but until then we have to live with this. EDIT: its still a open issue NuGet/Home#4856 |
Well its not pretty and doesn't completely solve this:
Result (folders still visible): EDIT: that Link actually also changes the folder where its deployed so that might not be preferable |
Ouch 😄 Thanks for checking though. Seems like this is tougher than I expected, let's hope we get a tooling update soon. Until then, we should mention that stuff in the docs when getting to the articles on the topic.
👍 |
Well seems the fact that files show up in the tree like that is 'by design' and thus won't be fixed... Atleast they recognized that being able to edit the files is a bug. |
Hm, I guess it makes sense when assuming that all package contents are deliberate user-side additions that are managed through VS - in that regard our use case just isn't the mainstream one. Still, it would be nice if there was some way to control this.
Assuming this is different from the I'm not 100% sure where this visible tag would be added on the package side, but since we are in control of the packages we release, and third-party authors could adhere to our guidelines for packages with content files, that might be a solution if it works. Edit: I'm not finding any way to specify visibility in the .nuspec / on the package author side - probably missing something here? |
Haha that doesn't explain all the issues that are made about this though :P
I don't understand what he is trying to say. We could probably come up with some csproj hack on the consuming project side that hides everything in the Data folder if this gets fixed https://developercommunity.visualstudio.com/idea/1079955/parent-folder-of-items-marked-as-visiblefalse-stil.html. Its not gonna be pretty though and controlling this from the nuget package would be better I think as the nuget package knows the intention of the files better. |
Alternatively, if the readonly fix is out there reasonably fast, that would be okay as well. As long as users can't edit these files, they'll get the idea that this is just something "for reference" and hopefully ignore them. Putting the file links into a subfolder named after the package like you did in the earlier experiment would also improve this. |
Summary
Just tested the new v4-alpha2 Duality project template and installed the Tilemaps sample package into the
GameEditor
project. Everything worked as expected, but there is one issue that might easily throw off new users and could also annoy experienced users:All the installed content files actually show up in the project in Visual Studio, and they can be edited via double-click. That alone would be tolerable, but any changes made are simply ignored and don't end up in the actual project.
There are a lot of internal theories on how Duality works that new users might develop based on that, most of which would lead them into the wrong direction, so I'm flagging this as a usability bug. If possible, we should fix that in some way before the actual release.
Analysis
Here's a number of ways this could be fixed, though I don't really know how difficult any of them would be - @Barsonax probably has a better idea on that topic.
The last one is probably a bad idea, since that would mean letting users edit the content files in their local package cache directory. I'd probably go with the first option to avoid any potential confusion in the first place, if there is a way to achieve that.
The text was updated successfully, but these errors were encountered: