Community
    • Login

    bak file as new default

    Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
    10 Posts 3 Posters 1.5k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Edzilla2000E
      Edzilla2000
      last edited by

      Hello,
      We deploy notepad++ to a lot of servers and it seems a recent update made the “simple backup” (a .bak file on save) the new default.
      This is very inconvenient for us, as it adds useless .bak files to git repos and other unfortunate locations.
      Is it possible to set up a default configuration to override such per-user settings?

      Thanks!

      PeterJonesP 1 Reply Last reply Reply Quote 3
      • PeterJonesP
        PeterJones @Edzilla2000
        last edited by PeterJones

        @edzilla2000 said in bak file as new default:

        This is very inconvenient for us, as it adds useless .bak files to git repos and other unfortunate locations.

        How horrible. I wonder if git has a configuration file to be able to ignore backup files; maybe they could call it semething unintuitive like .gitignore in the hopes that git users would never be able to find it with an internet search for “how do I ignore backup files in git?”

        (Less sarcastically, I’ve been doing backup-file ignores in my subversion repos for over a decade, so it’s not like Notepad++ is the first product to ever create backup files. In fact, some installations of subversion default svn:backup to ignoring common backup and temporary files.)

        Is it possible to set up a default configuration to override such per-user settings?

        Yes. That setting, like all the others in the GUI, is stored in the config.xml file which goes in the %AppData%\Notepad++ folder for each user. So when you install, you could either make your own zip/self-extracting-zip which has the modified config.xml, or you could overwrite config.xml after doing the normal installation.

        Edzilla2000E D 2 Replies Last reply Reply Quote 2
        • Edzilla2000E
          Edzilla2000 @PeterJones
          last edited by

          @peterjones I know about .gitignore, that still doesn’t mean I want bak files everywhere.
          The config.xml lives in the user profile. We deploy notepad++ on about 1000 machines, with close to 2000 users.
          I was rather looking for a machine-wide setting that we could set on install.

          PeterJonesP 1 Reply Last reply Reply Quote 0
          • PeterJonesP
            PeterJones @Edzilla2000
            last edited by PeterJones

            @edzilla2000 said in bak file as new default:

            I know about .gitignore, that still doesn’t mean I want bak files everywhere.

            Then don’t use git as an excuse for why you don’t want .bak files.

            We deploy notepad++ on about 1000 machines, with close to 2000 users.

            Then write a script which copies the modified config.xml to all the machines and users.

            With that many machines and users, I would assume you are already using scripting of some sort to run the installers in the first place; so just add the config-copy after the installer-run.

            I was rather looking for a machine-wide setting that we could set on install.

            There is no machine-wide setting that affects that. It is stored for each user in that file. Sorry. Even if it was machine-wide, with 1000 different machines, you’d have to write that file to 1000 different machines, so my suggestion of copying the config file(s) using a script (preferably the one you’re already using for installation) is still the best answer I can give.

            (I don’t deal with installing on large groups, but I was under the impression that there were lots of industry-standard choices for doing bulk installations across multiple machines/users that not only did the installations but copied config files as well. If you don’t have such a solution, I would look into it if I were you. We can’t help here, because we’re about using Notepad++, not the IT-style deployment questions.)

            Addendum: I guess there is an alternate: instead of deploying normal installations, deploy portable installations, where you could set all the config files in the same zip, and then unzip to each machine/user, since in the portable, all config files are bundled in same directory as the executable. Though this would then not do the registry setup for default assocations, so you’d have to add registry updates to your script, instead of adding config-file-duplication to your script, which amounts to the same amount of work, in the end.

            Edzilla2000E 1 Reply Last reply Reply Quote 2
            • Edzilla2000E
              Edzilla2000 @PeterJones
              last edited by

              @peterjones Juste because I can add a file to gitignore doesn’t mean I want my local repos to be full of bak files.

              Use profiles are created at logon, AFTER installation.
              We obviously deploy software and config centrally, that’s actually EXACTLY what I’m asking for.
              See for example what firefox does to specify different settings from the defaults

              You could have just told me “there is no system wide configuration option” instead of explaining how to use a git repo, but thank you anyway. I’ll try opening a feature request.

              1 Reply Last reply Reply Quote 0
              • Edzilla2000E
                Edzilla2000
                last edited by

                It seems that notepad++ actually allows you to deploy a template config.xml, through the use of config.model.xml
                I’m not finding much documentation on how this works but I guess asking here will get me another sarcastic comment so I’ll try to work it out by myself.

                PeterJonesP 2 Replies Last reply Reply Quote 1
                • PeterJonesP
                  PeterJones @Edzilla2000
                  last edited by PeterJones

                  @edzilla2000 ,

                  instead of explaining how to use a git repo,

                  Since you brought up git, I thought I’d point out the workaround for getting git to ignore the backups. I knew it was tangential to the actual problem you were asking about, but I wanted to address it. But then things got too focused on that, and degraded from there

                  I’m not finding much documentation on how this works but I guess asking here will get me another sarcastic comment

                  There isn’t much documentation on how that works. If config.xml isn’t there, it will just copy config.model.xml to config.xml.

                  I’m sorry that I didn’t think of config.model.xml as a “system wide configuration file”, because that’s not how I think of it … but that’s because I always only install Notepad++ for myself, and my config.xml has existed for years, so I don’t think about how it gets created, and didn’t realize it would solve your problem for you.

                  Sorry that I used too much sarcasm in my replies. Sarcasm is still genetically ingrained in me, and it sometimes leaks into my interactions with strangers more than it should. You caught me on a bad day at the start, and then the subsequent replies, I was seeing the conversation filtered through that initial interaction.

                  1 Reply Last reply Reply Quote 3
                  • PeterJonesP
                    PeterJones @Edzilla2000
                    last edited by

                    @edzilla2000 ,

                    Continuing with another thought: As you said regarding the config.model.xml files, the usermanual documentation is rather lacking on the deployment perspective. Unfortunately, even though I am the primary usermanual contributor, I don’t have the expertise to write such a page to be added to the manual, so I wouldn’t know where to start with such a thing.

                    What would be great is if someone (hint, hint) who had just finished figuring out how to get things running smoothly for deployment were willing to lend a hand, by giving some notes, or at least coming up with a list of questions that deployers will likely want answers to, I might be able to start working on such a thing. I have created an issue for the usermanual, requesting help for this task – so replies can go there. (And I’ll try to avoid getting overly sarcastic again.)

                    1 Reply Last reply Reply Quote 1
                    • D
                      Dennis Mz @PeterJones
                      last edited by

                      This post is deleted!
                      PeterJonesP 1 Reply Last reply Reply Quote 0
                      • PeterJonesP
                        PeterJones @Dennis Mz
                        last edited by

                        This post is deleted!
                        1 Reply Last reply Reply Quote 1
                        • First post
                          Last post
                        The Community of users of the Notepad++ text editor.
                        Powered by NodeBB | Contributors