Topic: MyPlugins_Direct folder and SourceArch variable  (Read 1534 times)

0 Members and 1 Guest are viewing this topic.

MyPlugins_Direct folder and SourceArch variable
« on: September 13, 2016, 02:37:30 AM »

Zharif

  • Apprentice
  • *
  • Location: Germany
  • Date Registered: Sep 2016
  • Posts: 5
Hello to all forum members.

A very long time I've not been active anymore in creating scripts for Nunos Winbuilder.
I've to start my first post with a question.
I read several threads to get a more or less deeper entrance to the Win10PESE project.
While trying to create some plugins I stumbled about the SourceArch variable here.

I downloaded and extracted  "Win10PE_SE_2016-09-01.zip".
I followed this guide: http://theoven.org/index.php?topic=1208.0
...and put my plugins into the "MyPlugins_Direct" folder for testing purposes.

Although I provided a Win10x64 source (Dir: D:\Scr\Win10x64) the SourcArch value is always x86 for any plugin I put into the "MyPlugins_Direct" (Dir: D:\WB\Projects\MyPlugins_Direct) folder,
whereas it is x64 (which is right) if I put it into any subfolder of D:\WB\Projects\Win10PESE\Apps (just for testing).
The source information sections of the plugin "Images configuration" (Dir: D:\WB\Projects\Win10PESE\Images.script) also shows an x64 source architecture.
This issue screws up a plugin of mine for which it is necessary to know if the source achitecture is x86 or x64.

So, is this a bug or a feature?
From my understanding the value of SourceArch should always rely on the source achitecture of the provided Iso and therefore shouldn't change.?

Thanks much in advance for any guidance here

Re: MyPlugins_Direct folder and SourceArch variable
« Reply #1 on: September 13, 2016, 05:08:54 AM »

Lancelot

  • Gena Baker
  • Grand Chef
  • *****
  • Date Registered: Sep 2010
  • Posts: 7078
So, is this a bug or a feature?
None, It is your mistake somewhere.

 Following tutorial http://theoven.org/index.php?topic=1208.0
  Last picture of Reply #2 Additional Plugins
    Plugin under project gets SourceArch value from project during process.
       (on picture same plugin under 4 project)



To test:

add this line to your plugin to top of [Process] that is under MyPlugins_Direct

Code: [Select]
[Process]
Echo,"Test SourceArch %SourceArch%",Warn

make your build ("Big Blue Play") with your x64 source

click "Log" button on builder (under "Big Blue Play")
click "Save as log html"

you will see yellow warning message with
"Test SourceArch x64"


??

ps: If you figure out your mistake, let us know so I add to tutorial  :wink:
« Last Edit: September 13, 2016, 05:09:43 AM by Lancelot »

Re: MyPlugins_Direct folder and SourceArch variable
« Reply #2 on: September 13, 2016, 06:49:07 AM »

Zharif

  • Apprentice
  • *
  • Location: Germany
  • Date Registered: Sep 2016
  • Posts: 5
I see.
After my plugin is shared to the Win10PESE project I've to use the *.Link file file under AppsMy\Plugin.Link.
The created link seem to parse the correct SourceArch value to the script file if I run the plugins' "Run" button.?
Everything worked well while running the project ("Big Blue Play").
Thank you.

Re: MyPlugins_Direct folder and SourceArch variable
« Reply #3 on: September 13, 2016, 07:59:37 AM »

Lancelot

  • Gena Baker
  • Grand Chef
  • *****
  • Date Registered: Sep 2010
  • Posts: 7078
After my plugin is shared to the Win10PESE project I've to use the *.Link file file under AppsMy\Plugin.Link.

Wrong,
MyPlugins_Direct works directly with all projects, you do not need .link etc. you do not need any additional task

As in
Reply #2 Additional Plugins - http://theoven.org/index.php?topic=1208.0
only putting plugin file to folder is enough.


There is not information on your posts to reproduce what you have,
To clear things let's go step by step:

Only follow steps, no additional task, Step 1 on this post:

Step1:
+
Put this plugin
* Zharif_Test.Script (6.44 kB - downloaded 58 times.)

to your
\Projects\MyPlugins_Direct\AppsMy\ folder
( --> \Projects\MyPlugins_Direct\AppsMy\Zharif_Test.Script )

+
Refresh or Restart your builder

+
on builder left tree, do you see
Win10PE SE\AppsMy\"Zharif Test" plugin avaiable ????????


« Last Edit: September 13, 2016, 08:00:30 AM by Lancelot »

Re: MyPlugins_Direct folder and SourceArch variable
« Reply #4 on: September 13, 2016, 11:11:15 PM »

Zharif

  • Apprentice
  • *
  • Location: Germany
  • Date Registered: Sep 2016
  • Posts: 5
Lancelot, I suppose we misunderstood each other. If so, sorry for inconvenience.
Maybe the whole project was screwed up for whatever reason, so please let's restart and forget my second post.

I deleted my whole WB folder and created a fresh Win10PESE project from the Win10PE_SE_2016-09-01.zip.
Then copied "Zharif_Test.Script and my prevously mentioned plugin script to the clipboard (the latter contains the same codeline under "Process" section as your example file).
1. On Winbuilder: set the source dir.
2. On Winbuilder: went to "Win10PESE\Utils\MyPlugins Project Add".
3. On Winbuilder: clicked the green download button (not necessary here but I redownloaded it anyway).
4. On Winbuilder: clicked the "MyPlugins Direct" Button.
5. On Winbuilder: went to MyPlugins\MyPlugins Direct.
6. On Winbuilder: clicked the "Put your Plugins here" button and copied files from the clipboard to "D:\WB\Projects\MyPlugins_Direct\AppsMy\File Tasks" via Open_Dir dialog.
7. On Winbuilder: clicked "Refresh".
8a. On Winbuilder left tree I see "Win10PE SE\AppsMy\File Tasks\Zharif Test" and Script Title of the other plugin.
8b. On Winbuilder I went to the plugin "MyPlugins\MyPlugins Direct\AppsMy\File Tasks\Zharif Test" and clicked the plugin "Play" button. The MessageBox shows "Test SourceArch x64".
9a. On Winbuilder left tree I also see "MyPlugins\MyPlugins Direct\AppsMy\File Tasks\Zharif Test" and Script Title of the other plugin.
9b. On Winbuilder I went to the plugin "MyPlugins\MyPlugins Direct\AppsMy\File Tasks\Zharif Test" and clicked the plugin "Play" button. The MessageBox shows "Test SourceArch x86".

This is exactly what I did before as mentioned in my first post (assuming that the provided link to the tutorial should be enough to tell you what I did).
Honestly, It didn't come into my mind that I have to run/play added plugins from the Win10PSESE tree to get the correct SourceArch value (and maybe others).
My assumption was, that if I copy a script into the "MyPlugins\MyPlugins Direct" folder I have to run it from there.
However, it is interesting for me to know why SourceArch values of scripts differ in regard of their location inside the WinBuilder tree.
I hope my actions and my question are clear now, please be patient if not.

Re: MyPlugins_Direct folder and SourceArch variable
« Reply #5 on: September 14, 2016, 12:00:36 AM »

Zharif

  • Apprentice
  • *
  • Location: Germany
  • Date Registered: Sep 2016
  • Posts: 5
Edit:
8b. should be "Win10PE SE\AppsMy\File Tasks\Zharif Test"

Re: MyPlugins_Direct folder and SourceArch variable
« Reply #6 on: September 14, 2016, 12:21:23 AM »

Lancelot

  • Gena Baker
  • Grand Chef
  • *****
  • Date Registered: Sep 2010
  • Posts: 7078
I hope my actions and my question are clear now, please be patient if not.
All clear  :thumbsup:

9b. On Winbuilder I went to the plugin "MyPlugins\MyPlugins Direct\AppsMy\File Tasks\Zharif Test" and clicked the plugin "Play" button. The MessageBox shows "Test SourceArch x86".
I guess you mean you run plugin under
"MyPlugins Direct\AppsMy\File Tasks\Zharif Test"

It is (x86) naturally expected  :thumbsup:
 When you run plugin under "MyPlugins Direct" , it gets value from "MyPlugins Direct"
     "MyPlugins Direct" is only there to put 3rd party plugins


8b. On Winbuilder I went to the plugin "Win10PE SE\AppsMy\File Tasks\Zharif Test" and clicked the plugin "Play" button. The MessageBox shows "Test SourceArch x64".

  When you run plugin under "Win10PE SE" , it gets value from "Win10PE SE"

  Naturally, Same Plugin run under different projects,
    and you expect value to be taken from real projects not "MyPlugins Direct" , so everything ok here  :thumbsup:


However, it is interesting for me to know why SourceArch values of scripts differ in regard of their location inside the WinBuilder tree.
This is wrong.
 where ever you run plugin on winbuilder tree under a project, it gets values from project independent from real file position.

It is a good thing, you can test same plugin under
"Win10PE SE"
"Win8.1SE"
etc.

Maybe It is better you also download (or extract) other projects (SE and Gena) to same base folder to practice more.
 All SE + Gena => designed to work together under same base folder ;) . Here I have all on same basefolder,
   Also this makes life easier to test or add 3rd party plugins, 1 plugin available inside all projects.

Reminding, "MyPlugins Direct" is not a project to test things,
 it is only there to hold 3rd party plugins to get 1 plugin available on all projects.
   reminding, never put a plugin under project folder ;)

My assumption was, that if I copy a script into the "MyPlugins\MyPlugins Direct" folder I have to run it from there.
I added additional info not to do that to tutorial  :thumbsup:
now some reminders to the end of reply 2
2) Additional Plugins http://theoven.org/index.php?topic=1208.0




*******
I hope all clear now, if confusion feel free to post.

:turtle:
« Last Edit: September 14, 2016, 12:22:20 AM by Lancelot »

Re: MyPlugins_Direct folder and SourceArch variable
« Reply #7 on: September 14, 2016, 12:31:58 AM »

Zharif

  • Apprentice
  • *
  • Location: Germany
  • Date Registered: Sep 2016
  • Posts: 5
Quote
..."MyPlugins Direct" is only there to put 3rd party plugins...
I understand now - Thanks.

Quote
...I added additional info not to do that to tutorial
Nice done. I think a usefull addition to this tutorial.
Thanks again.

...Will go back coding  :smile:

 

Powered by EzPortal