Jump to content

PowerOfTheShell Plugin 1.5


Cptrico

Recommended Posts

Thanks great plugin. Has anyone else found that if there is no subpage and commands are just on the main page you can no longer access PC Monitor by remote clients.

I.E


<?xml version="1.0"?>

<main>

  <group title="PowerOfTheShell" enabled="True" maxResults="50">

    <page title="Share Management" pageId="1" subtitle="Tools For Shares" enabled="True">

	    <command title="Display Sessions" commandId="1" path="c:\program files\pc monitor\scripts\OpenSessions.ps1" arguments="" />

	    <command title="Display OpenFiles" commandId="2" path="c:\program files\pc monitor\scripts\OpenFiles.ps1" arguments="" />   

    </page>  

  </group>

</main>

Works with subpage

<?xml version="1.0"?>

<main>

  <group title="PowerOfTheShell" enabled="True" maxResults="50">

    <page title="Share Management" pageId="1" subtitle="Tools For Shares" enabled="True">

	  <subpage title="Information" pageId="2" subtitle="Retrive Share Info" enabled="True">

	    <command title="Display Sessions" commandId="1" path="c:\program files\pc monitor\scripts\OpenSessions.ps1" arguments="" />

	    <command title="Display OpenFiles" commandId="2" path="c:\program files\pc monitor\scripts\OpenFiles.ps1" arguments="" />

   </subpage>  

    </page>  

  </group>

</main>

Link to comment
Share on other sites

Hi Nick

Thanks for using my plugin.

The plugin is designed to have at lest one subpage to work. That's why. If you enable debug you would see a parsing error.

The sole reason is that you have the Group as the starter, which is just a title/header, and then you create a page, which you could think as a menu item that links to some commands/pages and this is where the subpage comes in :)

The page is a link that needs to open up for a new page(subpage) otherwise all the commands for the scripts would be in the main root and you would scroll for ever.

Which was why I decided to wait for 2.9.1 that supported pages so all the thing were not placed in the root.

Let me know if you need help for anything ;)

Link to comment
Share on other sites

Hi all,

Just released V1.2 of my plug-in. http://forum.pulseway.com/topic/274-poweroftheshell-plugin-10/page__view__findpost__p__1117

  • It now supports nested pages in the menu layout, please see documentation in the zip for more information on how to use this.
  • More information in log(trace) and on the clients themselves if the plugin is having an issue with e.g XML config or scripts.

The package contains like previously config examples ,but also now a script_pack is included with a pre-configured XML file ready to use all of them.

The XML file uses the nested layout to gather everything in one place, looks great.

Please have a look at the (readme-first) before you get started with this,

I could not have provided you this complete example, without all the help from digbyp.Thanks a lot for using my plugin.

Please, if you have any ideas to useful scripts or already uses some that we haven’t added yet, please submit them and I will add them in the next package.

Enjoy.

Link to comment
Share on other sites

  • Administrators

It's a great idea, however I think that including them in the packages on a "examples" folder would be better because if you happen to add 50 example scripts the client who just wants to try out the plugin will end up with a pretty big list of scripts to execute :lol: , not that it would be bad tho.

Paul.

Link to comment
Share on other sites

Hi,

Thanks for using the plugin ;) sorry for the name confusion Paul is digbyp I just sometimes have used digbyp and some times Paul. But it is the same person. Not that I don't want to give Paul Csiki credit :) he has made some cool plugins. But in this case it is Paul Digby. Think I will go for last name for now on :)

Link to comment
Share on other sites

  • 5 months later...

Hi all,

Just set mobile pc monitor up on my home pc and server last night, defo something I will be putting forward at work as we're looking into a system management solution!

Anyway, installed the plugin on my server, and pointed to some of my scripts already, works great! (got really confused at first 'cos it doesn't quite like "write-host" and some of my scripts had that in!

I want to be able to run basic commands from the xml, like; "add-pssnapin windows.serverbackup;get-wbsummary" is this possible?

Tried putting the above in path and I get an error:

"The term 'add-ps....' is not recognized as the name of a cmdlet,function..."

Any thoughts?

Thanks,

Ollie

Link to comment
Share on other sites

Hi there,

You need to always point to a ps1 script in the path. What ever you put in that script will pe parsed and run. The reason that the write-host cmdlet is not working is that as you know it writes to the host console ;-), which is not there since we use a plugin to run the code.

You can put what ever code you want in the ps1 script, please see the script pack for a lot of examples and how to format the output for PCM.

Thanks for using the plugin.

Best regards

Johnni

Link to comment
Share on other sites

Hi Johnni,

I thought that would be the reason!

Yeah, I guessed that, could be a nice feature maybe? To have like 'Command' as an alternative to path, that would fire that in the host console?

Very pleased with the results of the plugin so thank you, I've got three useful scripts on Windows Backup if anyone wants me to zip them up and post? :)

Thanks,

Ollie

Link to comment
Share on other sites

  • 1 month later...

Hi all,

Now finally I have released version 1.3 that supports PCM API 3.0 Input controls :)

A whole new range of scripts can now be created and executed from within POTS.

Go and check it out http://forum.pulseway.com/topic/274-poweroftheshell-plugin-13/#entry1117

Please let me know if you have any questions for this build, or you experience any problems.

Thanks again for using my plugin. :)

Cheers

Link to comment
Share on other sites

  • 2 weeks later...

Hi all,

POTS for PCM v.1.3 came with support for input controls. Now in v.1.4 there is support for “partial input controls”.

And what does that mean. It means that it is now possible to have a script that can run with or without all input controls assigned. Let’s think of a script where running it with only one input control, will generate a different output than running it with 3 or all assigned input controls. This makes it possible to create very flexible scripts that can take different parameters.

Also it is now possible to set the log level of the plugin in the configuration manager.

Check it out, and as always please report back to me if you have any questions or good ideas for improvements.

Cheers. :)

Link to comment
Share on other sites

  • 1 month later...

Hi Johnni,

Just found this plug in whilst trying to work out an easy way of running Powershell scripts. I'm a relative novice and still learning so this might sound like a silly questions...

I have installed the plugin into my PC Monitor Manager and I've modified a config.xml to try out however I don't understand where the config should be placed in my folders for the plugin to read it? At the moment I am getting the following error in iOS app...

"Problem detected in the parser, please check the XML file" "Error in the plugin"

Link to comment
Share on other sites

Hi spcurtis81,

Thanks for trying the plugin :)

the config.xml will be read from the plugin folder, if you place it in where the pcMonitorClient.dll and PowerOfTheShell.dll is then you should be good to go.

If it still says trouble in the parser, then maybe enable diagnostics in Pc Monitor manager under Settings - Diagnostics and remember to include diagnostics logging for plugins.

After that you can try again and find the trace.log located in the Pc Monitor client installation folder, and see what the error is.

Don't hesitate to ask again. :)

,

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...