On Monday, 16 October 2023 at 03:31:13 UTC, dan wrote:
I have some code that i would like executed before anything else is.

The code is to set an environment variable which is used by a library. I'm trying to find some way to avoid setting the environment variable on the command line, or in any shell script or initialization file.

I think the place to put such code would be in a 'static this' inside a module.

So i need some way to force my module to be initialized first, ahead of all others.

You may find this article enlightening:

https://devblogs.microsoft.com/oldnewthing/20050607-00/?p=35413
  • Forcing my modul... dan via Digitalmars-d-learn
    • Re: Forcing... Richard (Rikki) Andrew Cattermole via Digitalmars-d-learn
      • Re: For... dan via Digitalmars-d-learn
        • Re:... Richard (Rikki) Andrew Cattermole via Digitalmars-d-learn
          • ... dan via Digitalmars-d-learn
            • ... bachmeier via Digitalmars-d-learn
              • ... dan via Digitalmars-d-learn
    • Re: Forcing... Paul Backus via Digitalmars-d-learn

Reply via email to