Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6045775
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T07:09:44+00:00 2026-05-23T07:09:44+00:00

The following two paragraphs are background – they just explain why I need to

  • 0

The following two paragraphs are background – they just explain why I need to do such a weird thing. If you don’t care you can skip them and go directly to the question.
I’m a Vim user and I started learning C#. Naturally I want to use MSBuild as my makeprg. I want to bind hotkeys for common development operations – Build, Clean and Run. Since I want to set my hotkeys globally, I have a problem as the files’ names are different in each and every project.

In GCC/MinGW this problem could be solved easily – since I’m already storing the important file names in variables, I can simply add to the makefile targets for cleaning the build and running the program, and then bind hotkeys to “:make! Clean” and “:make! Run”. So I figured I could do the same thing with MSBuild targets. It works great for Clean with the Delete tag(not sure I really need clean in .NET, but you know – force of habit), but I have a problem with Run.

Now, this is my problem: unlike GCC/MinGW’s makefiles, which are simply clever batch files that run shell commands, MSBuild uses it’s own set of commands and runs them internally. That means that Exec tasks run the program without a shell – I can open windows, but I can’t use it to test interactive shell programs.

Is there any way to persuade MSBuild to give me an interactive shell?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T07:09:45+00:00Added an answer on May 23, 2026 at 7:09 am

    Have you tried some variation of this,

    <Exec Command="start $(COMSPEC) /k &quot;$(PathTo)\My.exe &amp; exit&quot;" />
    

    After escaping it works out to roughly this,

    C:\Windows\system32\cmd.exe /k "PathTo\My.exe & exit"
    

    Which will run your command within a command shell (/k may not be the right cmd switch for your usage), then when your interactive program exits, it will run the “exit” command and move on.


    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Can anyone please explain what the following two paragraphs mean, in simple english? (Taken
The following two forms of jQuery selectors seem to do the same thing: $(div
Consider the following two scenarios (Edited just to complete the whole question and make
I have the following two tables: Package id ClientPackage id clientNumber packageId The thing
The following two queries each give the same result: SELECT column FROM table GROUP
Take the following two lines of code: for (int i = 0; i <
Suppose I have the following two strings containing regular expressions. How do I coalesce
Consider the following two ways of writing a loop in Java to see if
I have tried the following two statements: SELECT col FROM db.tbl WHERE col (LIKE
Consider the following two alternatives: console.log("double"); console.log('single'); The former uses double quotes around the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.