Jump to content

Mike Torrettinni

Members
  • Content Count

    1509
  • Joined

  • Last visited

  • Days Won

    3

Everything posted by Mike Torrettinni

  1. Mike Torrettinni

    Is it possible to see Git current working branch in IDE?

    Thanks, I know yes. I did enable Git in IDE and saw the options, but that's pretty basic.
  2. Mike Torrettinni

    Is it possible to see Git current working branch in IDE?

    Never mind, I copy pasted another ? char in the line. They return the same! Sorry
  3. Mike Torrettinni

    Is it possible to see Git current working branch in IDE?

    I have git version version 2.28.0.windows.1. You?
  4. Mike Torrettinni

    Is it possible to see Git current working branch in IDE?

    this works for me better, it gives me branch name: git branch --show-current while your suggestion gives me last commit id in current branch, so something like '6d2fab...'
  5. Mike Torrettinni

    Is it possible to see Git current working branch in IDE?

    No, no, that was not my intention... it's just about getting branch name into the Delphi IDE.
  6. Mike Torrettinni

    Is it possible to see Git current working branch in IDE?

    Yes, that looks good. I assume the info stays there when switching to .cpp code, right?
  7. Mike Torrettinni

    Is it possible to see Git current working branch in IDE?

    I enabled Git in IDE, but no info on what branch you are working on. Shame, it would pretty useful if there would very clear info, something like [Git: branch name], either in IDE title or in Project name in Project manager. Too bad.
  8. Mike Torrettinni

    Is it possible to see Git current working branch in IDE?

    @Lars Fosdal thanks, I know how the info is in Sourcetree, but i want to see in IDE what feature (branch) the opened project is about. Didn't know of it, will check. Thanks.
  9. I just had a little issue with a website backup and hard time rolling back some changes, so decided to put it under the source control. I wish I had done this sooner, so I'm thinking what else makes sense to put under source control, like: documentation, various scripts. Do you also put 3rd party source code under source control? I rarely change anything, but I do have some patches I apply to some components on new install. What do you guys have under source control?
  10. I've never done any restore that involve registry settings, except running registry patches like regarding disabling some Delphi packages that slow down IDE. So, I was just trying to understand what you are referring to, perhaps something it's useful for me too, but never realized that's a good idea to have backup of.
  11. You backup the whole Registry or just patches you run manually after installations?
  12. It says: "Note that you need to ask your backup vendor specifically whether they offer a 3-1-2 as shown or if they offer only a 3-1-1 (one copy in the cloud.) Don’t accept only a single copy in the cloud – it simply doesn’t offer the protection afforded by modern continuity and backup solutions." Is anybody really doing this? Requiring their backup vendor to have 3-1-1/3-1-2 backup of their data? So, if I have have 3 backup copies of my source, and vendor has 3 backup copies of what I upload to cloud backup... there are 6 backup copies of my source! And if that backup vendor is using a 3rd party backup vendor for one of the copies... 🙂 🙂 🙂
  13. Thanks, interesting. Definitely something to think about, but for sure need to clean up any large files, like zip, pdf, psd... also found a few 150MB .rsm files.
  14. I assume same for Git, right? So I can put a lot of non-source stuff (icons, docs, scripts...) into single repository and it will push only deltas to github.
  15. For files, right? Or are you talking about notes like Google Sheet and Google Docs?
  16. Wow, you guys are really doing it the right way. I guess some learned the lesson, like I just did - the basic backups don't always solve all problem or make it easy to restore older version. I will need to rethink this whole thing. I have github as backup and I see they have 2GB and 50Gb packages, so it should handle all my stuff.
  17. I noticed TDprojParser class that changes FileVersion in dproj file.: https://blogs.embarcadero.com/change-dproj-file-and-product-version/ It seems to do a good job. Anybody using it? I also noticed this thread about that people are using simple find/replace tools: https://en.delphipraxis.net/topic/4413-how-to-set-version-number-for-all-the-projects-in-a-project-group/ I know probably best option is creating .rc file, but if I opt for second-best, anybody ever found any issues with changing .dproj file while building projects?
  18. Mike Torrettinni

    Anybody changing FileVersion directly in dproj file?

    That's why I gave up on .rc file, after 2h I couldn't make it work on new empty project, so I can't imagine it's worth investing time for all my projects, because I'm sure each of them will have it's own little quirk and valid reason why it's not working. Setting version in .dproj file on build and commit worked out of the box and every time, since.
  19. Mike Torrettinni

    Get Parent process Current directory

    I'm experiment with some scripts and trying to get Parent info of the process. This is my call: I run a batch file, starting point: c:\Develop\ and batch file calls my Delphi's Project1.exe in Win32\Debug\ folder. I see in Process Monitor (mouse hint) that it has a Current directory of a Parent that executes my Delphi Project1.exe: Looking at Task manager I see this about the Parent process (19916): In Delphi I can get Parent PID, exe name and full path, so I can get Image path name, not sure how to get Command line info, but more important is Current directory (that is not in Task manager, but in Process Manager tool). I use CreateToolhelp32Snapshot to get Parent process info, PID and full path name. So, I want to find out what was the starting point or Current directory of the batch file that calls my Project1.exe. Any idea how to get this Parent's Current directory info?
  20. Mike Torrettinni

    Get Parent process Current directory

    I do relate to this! 🙂
  21. Mike Torrettinni

    Get Parent process Current directory

    Photoshop was just an example of impossibility for me to ask/force all these big companies to customize their tools to fit the needs of my tool. Just because they don't make it easy, doesn't mean it's not possible. Like I said, the user manual setup works just fine, the value of the tool is well worth even if the manual change is needed a few times a day - but it's annoying and now I'm investigating this option.
  22. Mike Torrettinni

    Get Parent process Current directory

    OK, let me try with example, lets look at Photoshop. Imagine it can be setup so each currently opened file you work on has it's own temp/permanent folder that contains scratch files, history, backup files... basically anything related to your .psd file. And you have a plugin/external tool that extends Photoshop features, based on all those files (perhaps you can look at the history, and pick and choose from it; perhaps there are files that contain brushes... anything that Photoshop doesn't make available on it's own). And Photoshop has an option to send a current working filename to your external tool and it only sends filename, but not the current working folder that has all the other files. The information about that folder is available for users to setup in Photoshop, so they know exactly where it is, but your tool doesn't. So, you can't really go to Adobe and ask them to modify their script to pass all the info you need, to make it easier for your tool. And the way Photoshop 'calls' your external tool is with a cmd from the current working folder of the current opened file. And this is the info your tool needs to work with to be useful. Yes, it took me a while to realize that Parent process is not persistent and even if it was, it's not easy to get it's current working dir, because the OS doesn't have this info just readily available.
  23. Mike Torrettinni

    Get Parent process Current directory

    Perhaps I don't know that it's possible, but can you identify what was the current directory that your project was called from? Please share the code.
  24. Mike Torrettinni

    Get Parent process Current directory

    Exactly, not reliable. I need to know where the the line was executed because this is current directory of the process that executes my project. And if Parent would always be persistent process, this would be Parent's current directory. So, I was hoping for function GetProcessCurrentDirectoty(ParentPID): string; 😉 Now, I will have to use batch file to get the current directory and pass it to my project.
  25. Mike Torrettinni

    Get Parent process Current directory

    Thanks, I did see similar scripts, some in Delphi already. Like Raymond says "Once the process can access its own command line, the kernel’s responsibilities are done. ", I guess is not completely true, since the command line is displayed in Task Manager. Same for Parent process current directory, not easily accessible. But if Parent process is not running anymore, then there is no info to get anyway.
×