Jump to content

Leaderboard


Popular Content

Showing content with the highest reputation on 08/31/21 in all areas

  1. Stefan Glienke

    We use DUnitX and it discovers all our silly mistakes before release

    Working on some better integration and result format that can be consumed by state of the art tooling such as https://github.com/danielpalme/ReportGenerator or https://github.com/marketplace/codecov but thats a side project that I don't spend much time on. Also still fighting some spurious crashes with DelphiCodeCoverage that result from it putting its breakpoints where it really should not (I suspect some incorrect debug information from the map file).
  2. see also: delphi - XE4: How to change exe output name base on platform? - Stack Overflow
  3. In Project Options - Building - Build Events select All configurations - Windows 32-bit platform. Then in Post-build events set Commands to ren $(OUTPUTPATH) $(OUTPUTNAME)32$(OUTPUTEXT) Note, that you won't be able to debug that.
  4. David Heffernan

    Get Parent process Current directory

    Then you are in trouble because there's really no way in general to be sure that the process which created your process still exists when your process executes. Windows has a very different model of parent/child process relationships from say Linux. What problem are you trying to solve?
  5. Lars Fosdal

    Get Parent process Current directory

    If the parent process runs at a higher security level than your own, you will have a hard time gleaning info from the process without elevating your own process. Since CreateProcess explicitly can specify a different working directory than the current (i.e. the parent) - there is no bullet-proof way of knowing the actual working directory of the parent process.
  6. From an old blog post from Allen Bauer (https://blog.therealoracleatdelphi.com/2009/09/: " All eligible class constructors and class destructors are invoked in sequence with unit initialization and finalization, respectively. If a given class constructor or destructor is eligible to be invoked (ie. it was linked into your application), it will run immediately before the initialization section for the unit in which the class is implemented. The class destructors will be invoked immediately after the finalization section for the unit in which the class is implemented. Class constructors in a given unit are generally invoked in the same order of declaration, except in cases described below. Class destructors are invoked in reverse order from the class constructors. For an ancestor class declared in the same unit, its class constructor will be invoked before the descendant class constructor and the class destructor is invoked after the descendant class destructor. If the implementation of given class constructor references another class in the same unit with a class constructor, the referenced class’ class constructor will be invoked before the current class’ class constructor. If the references are cyclic (ie. they reference each other in their class constructors), then they are invoked in reverse order of declaration. This means that there can be cases where a class constructor can reference an “unconstructed” class. Ancestor classes from external units used in the interface section are guaranteed to already have their class constructors run prior to any class constructors on descendant classes within the current unit. Unit cycles can break down the deterministic nature of the above rules in the same manner as unit initialization and finalization. However, for a given unit, it is guaranteed that all the class constructors declared within in it will have already run immediately before the initialization section runs. Congruent to this rule is that it is guaranteed that all the class destructors will run immediately after the finalization section. Dynamically loaded packages, using LoadPackage. Because there is no way to know exactly which classes are going to be used, just like there is no way to know which units are going to be used, all class constructors and destructors along with all unit initialization and finalizations are invoked according to the above rules. Other rules about their use are: You do not have to declare a class destructor if you declare a class constructor, and vice versa. They cannot be virtual, dynamic or message. They cannot be explicitly called. They cannot have any parameters. They do not have to be called Create and Destroy. (ie. Init and Fini are equally valid names). With this implementation, it was easier to leverage the same table that the compiler creates for unit initialization and finalization. It satisfies this requirement: “Called automatically to initialize the class before the first instance is created or any static members are referenced.” Issues with cycles are also clearly warned against in VB.NET and C#: “Avoid circular references in Shared … since it is generally impossible to determine the order in which classes containing such references are loaded.” Another benefit is that since it is running during the initialization/finalization phases, any threading implications are no different than the existing rules regarding unit initialization and finalization." What we don't know is, if the compiler behavoiur has changed since then.
  7. Fr0sT.Brutal

    Get Parent process Current directory

    Child process inherits current directory. I doubt it's possible to get parent's CDir with any API except by injecting and other hackish methods
  8. Anders Melander

    Better context menu

    It's transparent when the mouse isn't near it. When the mouse is over it it becomes fully opaque. Just like the one in MS Office. Personally I don't much care for that control as it usually gets in the way of what you're doing - but as you can see I've used it in a few places (above is from Better Translation Manager).
  9. You mean to define a NEW type, like that type TFileTypeRange = ftPDF.. ftXLSX; I think you can do that in certain local scopes and places, but does this really make sense ? The real goal of enum's is, when they were shared and used to guarantee correct values between several units, like pre-defined constants.
  10. dummzeuch

    FinTech anyone?

    I never heard that term either, but I'm not American. I heard of Fintech though, not sure what it means other than just another buzzword about making money with other people's money.
  11. tobiasgiesen

    SFTP client

    Hello, I would like to let you know that the uploading permissions bug has been fixed in the latest TGPuttyLib version.
  12. But it's not just a source repository. It has 70+ third-party integrations and offers tickets, milestones, kanban, wikis, code reviews. Other features like webdav file sharing, and multiple authentication enhancements like single sign-on, authorization by branch level. For those that want to host it themselves, there is a on-premise edition available. It's like a private GitHub repo with many features, including SVN support. It allows a mix and match of SVN, Git, and Mercurial repositories so if you are working with multiple teams with different types of repos you can support it with one system. If you only have 3 developers, and if your repo is under 1GB, then it might be something to look into so you get out of hosting it yourself and you get all the tools/integrations for free. I tried it out last night and the Wiki markdown support was OK, but the pages were all presented in a single list - there didn't seem to be the concept of child pages like on Azure Devops so I don't think I'll use it. Regardless, it's an interesting offering.
  13. If you are sharing the sources only inside your company, a local server is indeed a valid solution. I my case I am sharing sources with different customers, where a local server hosted in my intranet is almost out of scope (or comes with a lot of maintenance need). Therefore I prefer hosted servers that can be reached 24/7 from outside my place. What makes it a bit complicated is the restriction that some customers require the data to reside in Germany or at least the EU (while the latter turns out to be a moving target these days). This is why I recently asked in the German sibling of this forum about setting up a Kallithea instance (I am still fond of Mercurial - despite the crowd either stays with SVN or moved to Git. Hey, I am doing Delphi! What did you expect? Running with the majority?). Unfortunately (or better thankfully) that died during the first steps going to get it running. The only service I currently know of that satisfies all these requirements is Versionshelf by Shelf Cloud. Although, they don't offer a free account.
  14. You have to maintain the Linux box. You have to maintain the svn server. If you have it hosted then somebody else does it all.
  15. Vandrovnik

    SFTP client

    Today I found and just briefly tested this: https://github.com/superflexible/TGPuttyLib
  16. David Heffernan

    Addendum to Martin Fowler quote

    @emailx45 Perhaps there's a language barrier, but in this topic we are talking about the efficiency of the code generated by the compiler. Because for me there has been nothing added since XE7 that would bring enough benefit to justify the time cost of migrating.
×