1

I have an application written in AS3 which I need to be able to start up from my C# application. I have a prototype that does this just fine but my question is in relation to how I would arrange my solution to accommodate for this.

The way I had it in the prototype was using a post build script to copy the AS3 program directory into the output directory (Release or Debug), I then referenced it using Path.Combine as below:

private const string AS3_APP = Path.Combine(Path.GetDirectoryName(Assembly.GetEntryAssembly().Location), "ApplicationDir", "AS3App.exe");

For something that's going into full development with long term support (probably a few years supporting this project, minimum) I'm wondering if there's a cleaner way of doing this. Something that is quite obvious to other working on the project but also isn't overly brittle.

The current thinking is that we will have a requirement to compile this AS3 application and then bring it into the solution; however as it is basically a Program Files folder, it'll be on the .gitignore. We will then use a post build script as I have done already which will copy the AS3 application into the output directory, but this feels quite hidden and awkward.

Are there any easier ways to do this in C# or any better ideas?

  • 1
    Have you looked into option of creating an internal nuget repository and publish those binaries there? – Low Flying Pelican Feb 27 '15 at 21:59
  • @LowFlyingPelican No I hadn't considered that, I'll give that a go and see how that works out. Sounds like it could provide the clarity to people on the project that I'm after but also the separation. Thanks! – Elliot Blackburn Feb 28 '15 at 19:50
0

In the end I put the compiled version into the main repository. The binary is required for it to run and so it's an actual dependency we decided.

We're only ever running the latest version of that executable so decided using tests etc against it's functionality won't be a problem. The approach just feels messy but we decided this would be the best approach for now.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.