473,725 Members | 2,232 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

MSBUILD: how to find out current folder of imported file

Hi,

Issue at hand is that i want to have common build scripts, but people may be
multiple version (source trees) on single machine. How can i traverse parent
tree.

so what i thought is that i would put ..\env.Build file

when it reaches to root (where it knows location of common scripts).
then it will init variable to that folder.

problem is that how to find folder of imported build file.

or if i have a path string is there some string manuplution in msbuild that
would allow me to extract path info.
etc

Thanks,
Sajjad
Jun 6 '06 #1
1 2628
Hello Sajjad,

MSBuild provides a set of reserved properties that store information about
the project fille and the MSBuild binaries. For example,
$(MSBuildProjec tDirectory).

For deatils on this, you may refer to:

http://msdn2.microsoft.com/en-us/ms164309.aspx

Regards,

Luke Zhang
Microsoft Online Community Support

=============== =============== =============== =====
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
=============== =============== =============== =====

(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Jun 7 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
1707
by: Joshua Flanagan | last post by:
First, if there is a more appropriate newsgroup for MSBUILD questions, please let me know. I am trying to figure out how to create an item group that is evaluated AFTER some tasks have already run. For example, the build file will create a folder, and then copy various files into that folder. I then want a task to do something with all of the files in that folder. The way I currently have it setup will not work. I define a folder:...
2
1604
by: minorguy | last post by:
I have a general question about MSBuild (which I know little about so far) and I hope this is the right newsgroup. I can read the reference documentation about MSBuild, but it's not really telling me what I want to know. Perhaps someone can point me in the right direction. We have several projects, mostly C++, that we develop with Visual Studio 2005. I would like to automate this process. All of the targets, executables and DLLs, need to...
5
4470
by: Al | last post by:
Hi all We have created a xml file that imports a single project using the Import element. This project compiles to a class library, but has references to two other projects that are also class libraries. We are having a path reference issue for the depending projects; if the build is started in another directory than that of the imported project. (It's a simple cannot find project xyz.csproj, build fails.) If we place the xml file in...
2
8155
by: Jonathan Kacprowicz | last post by:
I am trying to create a build process using MSBuild that will build my multiple projects all with the same AssemblyVersion and AssemblyFileVersion. I have tried using the AssemblyInfo task from the community tasks projects (http://msbuildtasks.tigris.org/) and the AssemblyInfoTask from the MSBuild blog (http://www.gotdotnet.com/codegallery/codegallery.aspx?id=93d23e13-c653-4815-9e79-16107919f93e). My scenario is this: I have several...
3
6837
by: Danny | last post by:
Hi I trying to master msBuild but have a problem. I have a solution that I wish to build using msbuild but want to override BeforeBuild/AfterBuild targets for each of the projects. I trying to avoid modifying the common.targets etc and the individual project .sln files and just do it within a solution proj. One method I've tried, is to create the .proj file from the .sln file using the msbuildemitsolution enviroment flag- base upon
2
1660
by: K B | last post by:
I'm sorry to post OT here but I was hoping that someone could help me. I use Visual Studio 2005 and suddenly my Find feature has completely stopped working. When I select it, the screen flickers briefly...then nothing. I've tried reinstalling and the Ctrl+scrollbreak recommendation I found on line. Microsoft knowledgebase has nothing. Any suggestions...I use this a lot in development. thanks! Kit
0
1180
by: Karel Kral | last post by:
Hello, I have medium-sized solution in VB.NET (70 000 lines). The project compiles ok under VS2005, without any errors, without any warnings. But when I compile the same solution under MSBuild (from command line), strange things happenes. Compiler executed by MsBuild reports unknown types where it should by known. After whole day of investigation is have found, that imported namespaces are randomly "lost".
9
2916
by: Keith G Hicks | last post by:
I'm having a lot of trouble with "file in use" errors in my "folder watcher" project. Starting and stopping the watcher and reading my XML file work fine. Once the watcher is started, I'm reading the text files from the watched folder line by line into variables and then posting them to a SQL table. All of the code for the form is shown below. And it works fine except for 2 issues. First issue: In the Finally of the Try for teh SQL...
1
2522
by: chris.kennedy | last post by:
This is a little OT. I have a website which uses vb classes in the app_code folder which in turn call a data service. I want compile the app_code vb files into a separate dll (to use Sandcastle on them) with MSBuild (it's a bit of a work around). When I run my MSbuild file I need it to reference the classes created by service reference. How do I reference them in my build file. Is this a complete nonstarter. I have been told that we have...
0
9401
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
9176
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9113
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6702
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4519
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4784
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3221
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2635
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2157
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.