Sessions and presets handling

aureq

New Member
Hi,

I'm trying to use GIT as a way to version control my changes in NTLite. In version 1.7.1 6630 x64, it's not possible to set a separate preset folder so I can't easily track my changes/actions. I have to export my changes from the "Start/Source" panel, save the current session into a new preset, then copy the .xml file into my GIT repository and finally commit my changes.

Maybe some suggestion:
  • like the scratch/temp/updates folders, having a customizable presets folder location would be very helpful.
  • Having the ability to auto-save the loaded session (upon user changes) would also improve my source code versioning workflow.
  • Having the ability to perform a "one-click" save for the currently loaded session would also improve my source code versioning workflow.

I think ultimately, this could enable system administrators and developers to more easily export their presets and make them publicly available on Github for example.

Thank you for your consideration.
 
Well, you can load and save presets without processing the Windows image, not only by processing an image.

Load an image
Set changes
Go back to Sources
Save
If the Save button isn't enabled, click on the right side panel (the presets side panel).

The option 'New' undo all the changes you have done to the actual session.

You can rename the presets from the UI or right click and choose 'Open file location'.
Export preset is equal to copy from presets folder to another place, Import is the opposite.

Also you can use WinMerge to compare preset files or Beyond Compare from scootersoftware.

You can have folders in Presets folder but these folders won't be seen from NTLite.

Import Preset also works by drag and drop the xml file, the same applies to add sources folder to the image list.
 
Kasual Thank you for your reply.

This thread is simply to suggest improvements to make my workflow easier, so I don't have so many clicks to perform every single time to track one change.

Re: WinMerge: Using a software like GIT has this native feature already (git diff). It's simple and very effective like WinMerge but from the comfort of a command line.

Re: Presets folder: I'm not sure that storing data in the program installation path (C:\Program Files\NTLite\Presets\) is what's best. Something store in %APPDATA%/NTLite could be a good replacement. That would also allow presets separation between users.
 
Got your point.

I don't know how many people have the knowledge to use NTlite that uses your computer but %APPDATA%/NTLite isn't a noticeable improvement on my side as i'm the only one who uses NTLite but i understand your point.

I always install NTLite as portable and have over 100 NTLite folders that sometimes i can use to backtrack some changes.

Command lines can also be saved in a cmd file and launch by double click, easier if git would let to point to a folder and click the cmd instead of typing.

Maybe you can try in the beta version NTLite /? from command line (don't know if in stable ), many enhancements will come to the command line for sure.

You can see the presets folder layout thread and maybe add your thoughts.
 
Thank you Kasual.

nuhi I'm a fairly new user but something is getting me really confused or at least is un-intuitive.

I just found out that when you save a session it saves the state of your modification. As you apply these modifications, features/components are actually removed from the source and then the ISO is created (all good). Then I'm given the option to save my session in a .xml file. To my point above, I would like to track all my modifications through GIT so I can easily share with other people/organizations/github.

What I didn't realize is if you unload and reload the same source, many components/features aren't going to appear in the list of available features/components.

The confusing part: now, if I load my previous session, apply new changes and save/export my session, the resulting .xml file looses (some) my previous changes like <RemoveComponents>, <Features> and <Settings> at least (but probably more). This behavior makes it really hard for me to correctly track/share my changes since what I view as the final .xml file doesn't embed all the changes. This makes it impossible/really hard for me to share session states with other organizations.

As pointed out by Kasual, I guess someone could use WinMerge/GIT to compare the session files and merge back removed elements. But it has its own drawbacks such as the risk missing some elements, it would be a manual process prone to errors, some XML entities may be cryptic and hard to relate to specific changes, it may degrade NTLite stability if something unexpected is done.

Questions if you allow me:
  • Is this an expected behavior? I'm a total noob, so I may have missing something here.
  • Is there a workaround or a hidden setting? Again, I'm a noob, so my apologies if this is the case.
  • Is this something that you would consider as improvements to be put on a roadmap?

I really view NTLite as a great software and it would be awesome if users/sysadmins/developers/customers could share their session states (Github or other) so the entire community benefits from everyone else work.

Thank you.
PS: For other users/customers reading this and finding this a potential problem... here is a possible workaround - though this is quite time consuming.
  1. Copy an original Microsoft image into a R/W location
  2. Load the original Microsoft image from location in step 1
  3. Set your changes
  4. Apply your changes / create an ISO
  5. Save your session state

    If you need to reload a previous session state and keep previous changes in the session state, then

  6. Unload the image, and forget its location
  7. Clear the entire folder in which the image was loaded from (as in, delete all files)
  8. Copy your original Microsoft image from step 1 into the cleaned location (takes time)
  9. Load the clean image at step 8 (this will take time)
  10. Restore a session state as saved at step 5 (the .xml will contain your previous changes and that will match what's in the loaded image)
  11. Set/add/remove your changes
  12. Apply your changes / create an ISO
  13. Save your session state (the .xml file should contain all your changes)
Repeat from step 6 to 13, each time you want to add/remove more changes while keeping previous work into the .xml.
 
It would be awesome if users/sysadmins/developers/customers could share their session states (Github or other) so the entire community benefits from everyone else work.

Like this you mean? There is no one size fits all with this lark, wasnt with xp and there isnt now, even when it comes down to simple things like ui tweaks. Best you can do is please some of the people some of the time and in my case thats beginners, because we all have to start somewhere, right.

I went from liting xp straight to liting 7 and my brain just got up and walked away.
 
Last edited:
nuhi I was wondering if you had any comments on this please? Thanks.
Hi aureq

I'm glad to tell that you can use/run NTLite and use personalized preset path but only from the command line (/LoadPreset: "c:\temp\preset.xml"), check the changelog or run ntlite /? from the command line.

To build new presets you will need to run the UI and stick to the usual path.
 
Kasual The point you're making is correct but you're only addressing a micro detail of a much larger question. What I'm talking about here is user workflow, automation and consistency. Not just "how to use the software".
If the content of my XML looses information between 2 sessions this is obviously a bad thing if I track my changes through GIT. If I need to merge back the lost changes using a 3rd party tool, this is a waste of energy. If I need 20 clicks and commands, this is not helping in staying time efficient.

I'm saying this for myself but also a number of my customers who would like to use NTLite as a way to automate their OS base image for the cloud.

That's why I'm hoping nuhi will reply to this thread.
 
It's not to "how to use the software", running NTLite with a preset from any location is a new feature with the new released build, limited to a command line execution.
Comparison typing commands is really longer than have a script that could make it easy with a single click (time eficient). If a number of your costumers could be NTLite users,that makes more sense.

I'd like to see nuhi's answer, i'm interested on.
 
Back
Top