Jump to content











Photo
* * * * - 2 votes

MistyPE

winpe10 winpe5 winpe4 winpe3 winpe2 winpe

  • This topic is locked This topic is locked
384 replies to this topic

#101 misty

misty

    Gold Member

  • Developer
  • 1069 posts
  •  
    United Kingdom

Posted 19 April 2014 - 08:32 PM

@farda
Several items in your post do not appear to be present in WinPE (Pin to Start Menu, Pin to task bar and share with). To remove context menu entries for Include in library and Send to, try the following code -

If,Not,ExistRegSection,HKLM,_WinPE_SOFTWARE,RegHiveLoad,_WinPE_SOFTWARE,"%Target_config%\software"
// Remove "Include in library" from right-click context menu
RegWrite,HKLM,0x1,_WinPE_SOFTWARE\Classes\Folder\ShellEx\ContextMenuHandlers\Library Location,,
// Remove "Send to" from right-click context menu
RegWrite,HKLM,0x1,_WinPE_SOFTWARE\Classes\AllFilesystemObjects\shellex\ContextMenuHandlers\SendTo,,
RegWrite,HKLM,0x1,_WinPE_SOFTWARE\Classes\UserLibraryFolder\shellex\ContextMenuHandlers\SendTo,,
If,ExistRegSection,HKLM,_WinPE_SOFTWARE,RegHiveUnload,_WinPE_SOFTWARE
Regards,

Misty
  • farda likes this

#102 farda

farda

    Newbie

  • Members
  • 23 posts
  •  
    Iraq

Posted 19 April 2014 - 08:51 PM

hi i will test that.

actually i tested this method but since i want deleted that's i used "RegDelete". :fool:

and about "Pin to Start Menu, Pin to task bar and share with" i can see them on right click menu,i will try this method

thank you very much


Edited by farda, 19 April 2014 - 08:52 PM.


#103 misty

misty

    Gold Member

  • Developer
  • 1069 posts
  •  
    United Kingdom

Posted 19 April 2014 - 09:05 PM

 

...and about "Pin to Start Menu, Pin to task bar and share with" i can see them on right click menu...

Which build are you using? I did a quick test with a very minimal build (6.3.9600 - Windows 8.1 Enterprise Trial sources) and didn't see any reference to them in the context menu.

Regards,

Misty

#104 farda

farda

    Newbie

  • Members
  • 23 posts
  •  
    Iraq

Posted 19 April 2014 - 09:10 PM

windows7    6.1.7600

 

 
Which build are you using? I did a quick test with a very minimal build (6.3.9600 - Windows 8.1 Enterprise Trial sources) and didn't see any reference to them in the context menu.

Regards,

Misty


Edited by farda, 19 April 2014 - 09:25 PM.


#105 farda

farda

    Newbie

  • Members
  • 23 posts
  •  
    Iraq

Posted 19 April 2014 - 10:42 PM

@misty

your registry work

other registry is located in HKEY_CLASSES_ROOT so i must use HKCR instead of HKLM

but now i still use _WinPE_SOFTWARE or something else

 

to see sharing with go to users folder and right clck on one of the folder on that

and to see Pin to Start Menu, Pin to task bar go to 7zip folder and right click on the exe file


Edited by farda, 19 April 2014 - 10:45 PM.


#106 misty

misty

    Gold Member

  • Developer
  • 1069 posts
  •  
    United Kingdom

Posted 20 April 2014 - 06:34 AM

 

...other registry is located in HKEY_CLASSES_ROOT so i must use HKCR instead of HKLM but now i still use _WinPE_SOFTWARE or something else...

Try adding the required settings to SOFTWARE registry hive in the offline WinPE - this appears to populate HKEY_CLASSES_ROOT when WinPE is running.
 

...to see sharing with go to users folder and right clck on one of the folder on that
and to see Pin to Start Menu, Pin to task bar go to 7zip folder and right click on the exe file

Found the Pin to Start Menu - it's not present in WinPE 5.0 so I tried using WinPE 3.0 and found it. I'll play around with some settings based on the reg file you posted previously. I'm about to do an easter egg hunt with my girls and will be busy for most of the day so not sure when yet.

BTW, I still can't see any references to sharing - in either WinPE 3.0 or 5.0.

Regards,

Misty
  • farda likes this

#107 misty

misty

    Gold Member

  • Developer
  • 1069 posts
  •  
    United Kingdom

Posted 20 April 2014 - 10:06 AM

Hi farda,
To remove the Pin to Taskbar and Pin to Start Menu context menu options, try the following code -
If,Not,ExistRegSection,HKLM,_WinPE_SOFTWARE,RegHiveLoad,_WinPE_SOFTWARE,"%Target_config%\software"
// Remove "Pin to start menu" from right-click context menu
RegDelete,HKLM,_WinPE_SOFTWARE\Classes\*\shellex\ContextMenuHandlers\{a2a9545d-a0c2-42b4-9708-a0b2badd77c8}
// Remove "Pin to Taskbar" from right-click context menu
RegDelete,HKLM,_WinPE_SOFTWARE\Classes\*\shellex\ContextMenuHandlers\{90AA3A4E-1CBA-4233-B8BB-535773D48449}
If,ExistRegSection,HKLM,_WinPE_SOFTWARE,RegHiveUnload,_WinPE_SOFTWARE
A similar approach should work for Sharing.

Regards,

Misty
  • farda likes this

#108 misty

misty

    Gold Member

  • Developer
  • 1069 posts
  •  
    United Kingdom

Posted 24 April 2014 - 02:12 PM

Project updated -
  • Added a number of additional options in the core script - these are all enabled by default. The new options will remove a number of unsupported options from the right-click context menu. Thanks to reboot.pro forum member farda for these suggestions.
  • Added "Open with" workaround for WinPE 4.0/5.0. See - http://reboot.pro/to...-in-winpe-4050/
  • Added DMDE script
Regards,

Misty
  • farda likes this

#109 farda

farda

    Newbie

  • Members
  • 23 posts
  •  
    Iraq

Posted 25 April 2014 - 12:07 AM

@misty

thank you for adding them.also good add some other file removal From boot.wim if not damage pe loading.so output iso more small

removal for backup folder in winsxs

\Windows\winsxs\Backup

and unnedded  file in FileMaps folder.like $$_boot_pcat_fi-fi  that for other language

\Windows\winsxs\FileMaps

also there is so many other language folder in system32

like

\Windows\System32\cs-CZ or other language

and also .NLS in system32 folder

system restore and bitlocker too

 

thankyou



#110 misty

misty

    Gold Member

  • Developer
  • 1069 posts
  •  
    United Kingdom

Posted 25 April 2014 - 02:55 PM

@farda
I doubt that removing any duplicate backup files will make any difference as the .wim format does not store duplicate files - single instance storage is used. In regards to the other suggestions I'm reluctant to delete files that might be used in other setups - the language folders for example could be required depending on the source. Also, the language folders usually only contain .mui files which are relatively small - when compressed in a .wim I expect that the space they take up is negligible.

If you want me to post instructions so that you can create your own script to remove these files then please let me know and I'll do my best to help.

Regards,

Misty
  • farda likes this

#111 farda

farda

    Newbie

  • Members
  • 23 posts
  •  
    Iraq

Posted 25 April 2014 - 11:00 PM

yes please.



#112 alacran

alacran

    Platinum Member

  • .script developer
  • 2710 posts
  •  
    Mexico

Posted 26 April 2014 - 09:06 PM

@ misty

 

Please when you have time modify your Clonedisk Script to include brand new Clonediskx64 http://reboot.pro/to...-18#entry183877  on x64 builds, you could make only an update to this script and we can just overwrite the one in your last MistyPE 2014-04-24.

 

Best Regards



#113 misty

misty

    Gold Member

  • Developer
  • 1069 posts
  •  
    United Kingdom

Posted 26 April 2014 - 09:21 PM

@alacran
I'm a little bit confused - I don't recall any Clonedisk scripts. I can easily put one together if required - in the interim simply use the Add Custom Folders\Files script.

Regards,

Misty

#114 alacran

alacran

    Platinum Member

  • .script developer
  • 2710 posts
  •  
    Mexico

Posted 26 April 2014 - 09:59 PM

Yes you are right, forgot I was adding it in 32 bits builds with a little script I made to add extra portables in v 2013/10/15 and v 2013/10/20 in order to have them inside boot.wim

 

Spoiler

 

Just downloaded last version and now I'm going to try it, please excuse me for my mistake, but my memory is not as good as it was.

 

Best Regards



#115 misty

misty

    Gold Member

  • Developer
  • 1069 posts
  •  
    United Kingdom

Posted 27 April 2014 - 08:29 AM

@farda
This is a sample script for deleting two directories (and any subdirectories they may contain) and two files. Please use this as an example and add to it as required -



[main]
Title=Farda request
Description=
Selected=True
Level=3
Author=Misty
Version=1
Date=2014-04-24

[process]
If,%Method%,Equal,inject,Begin
  echo,"Clearing read-only attributes from boot.wim"
  ShellExecute,Hide,"attrib.exe","-r #$q%Outputdir%\Sources\boot.wim#$q"
  //remove directory \Windows\winsxs\backup (note the use of --recursive for a directory)
  ShellExecute,Hide,"%Tools%\wimlib\wimlib-imagex.exe","update #$q%OutputDir%\sources\boot.wim#$q %Boot.wim.Image.number% --command=#$qdelete '\Windows\winsxs\Backup' --recursive#$q"
  //remove directory \Windows\System32\cs-CZ (note the use of --recursive for a directory)
  ShellExecute,Hide,"%Tools%\wimlib\wimlib-imagex.exe","update #$q%OutputDir%\sources\boot.wim#$q %Boot.wim.Image.number% --command=#$qdelete '\Windows\System32\cs-CZ' --recursive#$q"
  //remove file \Windows\winsxs\FileMaps\$$_boot_pcat_fi-fi_da1fe77a29be0007.cdf-ms (note the use of --force which is used just in case the file doesn't exist)
  ShellExecute,Hide,"%Tools%\wimlib\wimlib-imagex.exe","update #$q%OutputDir%\sources\boot.wim#$q %Boot.wim.Image.number% --command=#$qdelete '\Windows\winsxs\FileMaps\$$_boot_pcat_fi-fi_da1fe77a29be0007.cdf-ms' --force#$q"
  //remove file \Windows\System32\C_037.NLS (note the use of --force which is used just in case the file doesn't exist)
  ShellExecute,Hide,"%Tools%\wimlib\wimlib-imagex.exe","update #$q%OutputDir%\sources\boot.wim#$q %Boot.wim.Image.number% --command=#$qdelete '\Windows\System32\C_037.NLS' --force#$q"
End
An alternative method would be to use a file list (in this case \Projects\Cache\Programs\Misc\WimLibDeleteList.txt). In the following example I have used the command ShellExecute,Open,"cmd.exe","/K. This will display feedback from the delete commands and can be useful for troubleshooting.
[Process]
If,%Method%,Equal,inject,Begin
  echo,"Clearing read-only attributes from boot.wim"
  ShellExecute,Hide,"attrib.exe","-r #$q%Outputdir%\Sources\boot.wim#$q"
  ShellExecute,Open,"cmd.exe","/K #$q#$q%TOOLS%\wimlib\wimlib-imagex.exe#$q update #$q%OutputDir%\sources\boot.wim#$q %Boot.wim.Image.number% < #$q%Cache%\Programs\Misc\WimLibDeleteList.txt#$q"
End
Contents of \Projects\Cache\Programs\Misc\WimLibDeleteList.txt -
delete '\Windows\winsxs\Backup' --recursive
delete '\Windows\System32\cs-CZ' --recursive
delete '\Windows\winsxs\FileMaps\$$_boot_pcat_fi-fi_da1fe77a29be0007.cdf-ms' --force
delete '\Windows\System32\C_037.NLS' --force
When you are happy with it, you can always change this section to hide the wimlib process (also ensuring that the cmd.exe switch is changed from /K to /C) -
[Process]
If,%Method%,Equal,inject,Begin
  echo,"Clearing read-only attributes from boot.wim"
  ShellExecute,Hide,"attrib.exe","-r #$q%Outputdir%\Sources\boot.wim#$q"
  ShellExecute,Hide,"cmd.exe","/C #$q#$q%TOOLS%\wimlib\wimlib-imagex.exe#$q update #$q%OutputDir%\sources\boot.wim#$q %Boot.wim.Image.number% < #$q%Cache%\Programs\Misc\WimLibDeleteList.txt#$q"
End
Please note that these script examples will only work if you are building with the INJECT method. If you are using EXTRACT then let me know and I'll put some other instructions together for you.

Regards,

Misty
  • farda likes this

#116 farda

farda

    Newbie

  • Members
  • 23 posts
  •  
    Iraq

Posted 27 April 2014 - 10:25 PM

@misty

thank you very much for helping me

i created and tested both method.method 1 is slower and method 2 very fast. work without error,thanks to your easy learning

Download

 

but i opened boot.wim with 7-zip,it have two folder(1,2) and one XML file.

in folder 1 i see all removed file but in folder 2 i don't see them.so can i load wim file somehow

and manually delete them from folder 1?


Edited by farda, 27 April 2014 - 10:40 PM.


#117 misty

misty

    Gold Member

  • Developer
  • 1069 posts
  •  
    United Kingdom

Posted 28 April 2014 - 06:59 AM

@farda
Glad it worked. To delete the files from a wim containing more than one image, try -

[Process]
If,%Method%,Equal,inject,Begin
  echo,"Clearing read-only attributes from boot.wim"
  ShellExecute,Hide,"attrib.exe","-r #$q%Outputdir%\Sources\boot.wim#$q"
  ShellExecute,Hide,"cmd.exe","/C #$q#$q%TOOLS%\wimlib\wimlib-imagex.exe#$q update #$q%OutputDir%\sources\boot.wim#$q 1 < #$q%Cache%\Programs\Misc\WimLibDeleteList.txt#$q"
  ShellExecute,Hide,"cmd.exe","/C #$q#$q%TOOLS%\wimlib\wimlib-imagex.exe#$q update #$q%OutputDir%\sources\boot.wim#$q 2 < #$q%Cache%\Programs\Misc\WimLibDeleteList.txt#$q"
End
Just in case a directory is not present in both images in the wim, you might want to try adding the --force swith in your file list. E.g.
delete '\Windows\winsxs\Backup' --recursive --force
Method 2 is considerably faster. If I'd had a better understanding of wimlib-imagex when I drafted the MistyPE project I'd have used this method. I played around with this approach in MistyPE at the weekend and it saved nearly a minute in build time. I'm planning on adding this in the next release. Having said that, synchronicity (Wimlib author) is considering changes to the update add commands, so I'm going to wait a little while.

Regards,

Misty
  • farda likes this

#118 alacran

alacran

    Platinum Member

  • .script developer
  • 2710 posts
  •  
    Mexico

Posted 02 May 2014 - 12:28 AM

@ misty

 

Once again I'm asking for something, Could you please add WOW64 and UEFI support to your project?.   It can be very useful when building x64 PE's (as an option, if some one likes better a very minimal build just can uncheck it).

From wimb's post: http://reboot.pro/to...e-3#entry184053   I tried Win8.1SE (capable to boot from old BIOS and UEFI, and also run 32 bits applications on an x64 PE). I downloaded Win8.1u1 Enterprise evaluation and made a Win5.1x64PE which already tested but this project uses Windows dism & imagex and it takes long time to build a PE, also you need to extract ISO contend to HDD (as recommended).

I like better your approach using wimlib-imagex and extract needed files from an imagedisk mounted ISO (pretty fast building).   The mentioned project has a JFX’s script for WOW64 that perhaps with some modifications can be adapted to your project.

 

JFX WOW64 script: https://www.mediafir...jbrms28uns4auf1

 

 

Best Regards



#119 misty

misty

    Gold Member

  • Developer
  • 1069 posts
  •  
    United Kingdom

Posted 02 May 2014 - 08:40 AM

@alacran
I'll add these requests to my list of things to do. I'm not sure whether I'll be able to actually add WOW64 support to this particular project - I've had a quick look through JFX's script and it's pretty complex. It should be possible to port most of it however I'm just not sure what WOW64Patch.exe (attached to the script) actually does. I'll play around with it when I get the chance, however if I'm honest it's not my highest priority right now. In regards to UEFI support - I have no hardware to test this on. I will still look into it though.

Regards,

Misty

#120 alacran

alacran

    Platinum Member

  • .script developer
  • 2710 posts
  •  
    Mexico

Posted 02 May 2014 - 11:05 AM

@ misty

 

Thank to you for your quick answer, take your time.

 

I like your project very much and I want to do all my WinPE's with MistyPE, there is no limit for the host/build OS's, I already have builded WinPE's from 7x86, 7x64, 8x86, 8x64, 8.1u1x86 and 8.1u1x64 ISO's under XP-SP3 x86 and 7x64 host OS's and the only time something was wrong it was my fault (forgot to put Ghost files in the folder),  so I can be sure every build is a success.

 

Best Regards



#121 misty

misty

    Gold Member

  • Developer
  • 1069 posts
  •  
    United Kingdom

Posted 02 May 2014 - 07:53 PM

@alacran
Thanks so much for this positive feedback.

:cheers:

#122 alacran

alacran

    Platinum Member

  • .script developer
  • 2710 posts
  •  
    Mexico

Posted 02 May 2014 - 08:28 PM

@alacran
Thanks so much for this positive feedback.

:cheers:

Just facts



#123 alacran

alacran

    Platinum Member

  • .script developer
  • 2710 posts
  •  
    Mexico

Posted 03 May 2014 - 08:17 AM

@ misty

 

I found some additional info about WOW64, I think it can be useful to you, please do not think I'm pushing you to do this, take your time and when you think it's the right time look at this info, starting from the WOW.doc

 

https://www.mediafir...vz2hve4hkhbdyd4

 

Best Regards


  • misty likes this

#124 misty

misty

    Gold Member

  • Developer
  • 1069 posts
  •  
    United Kingdom

Posted 03 May 2014 - 01:17 PM

...I found some additional info about WOW64, I think it can be useful to you, please do not think I'm pushing you to do this, take your time ...

@alacran
Don't worry - I don't (think you are pushing me to do this). Thanks for the information you linked to - it looks very useful :thumbsup:

Regards

Misty

#125 kronus

kronus
  • Members
  • 9 posts
  •  
    United States

Posted 03 May 2014 - 02:25 PM

wasn't able to get a build from any os iso. i think this misty build is like all the winbuilder builds very bad. need a better way to make a custom pe without doing it manually someone else have a better way?

 







Also tagged with one or more of these keywords: winpe10, winpe5, winpe4, winpe3, winpe2, winpe

1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users