Environment Variable for AppData\Local / Access Downloaded custom assemblies

余生颓废 提交于 2021-02-15 11:12:23

问题


I am trying to setup my TFS2010 Build and I want to access the files that are downloaded via the "Version control path to custom assemblies".

From what I can tell those files are downloaded to:

C:\User\<Build User>\AppData\Local\BuildAgent\<Built Agent Number>

I can directly access that folder via the above path, but it would be nice if there was an environment variable (or something I can use in the build) to access that folder indirectly.

Or... Is there a better way to get at these files? (I am putting a version file in there to be downloaded every time the build is run).


回答1:


You can use %LOCALAPPDATA% environment variable. It expands to

RootDrive:\User\LoggedInUser\AppData\Local


Example: %LOCALAPPDATA%\BuildAgent


Note that %APPDATA% will expand to

RootDrive:\User\LoggedInUser\AppData\Roaming



来源:https://stackoverflow.com/questions/4128759/environment-variable-for-appdata-local-access-downloaded-custom-assemblies

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!