Sponsored Content
Top Forums UNIX for Advanced & Expert Users Running Powershell Script from Linux through Cygwin Post 303020741 by rbatte1 on Thursday 26th of July 2018 11:54:40 AM
Old 07-26-2018
Can you get a very simple proof of concept script to work? A quick "Hello-world" through the same mechanism would hopefully show if it is the process of elevating privilege or the commands actually running that is the problem. So a
Code:
ssh odshekhar@Windowsmachine  'powershell -executionpolicy bypass -File  "C:\scripts\hello-world.bat"'


What output/errors do you get?



Thanks, in advance,
Robin
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Running a.out on Cygwin

I wrote and compiled a program on a unix machine using g++. Now I copied it over to the machine with the Unix emulator Cygwin. I tried to run it by entering "a.out" in the command prompt but was given: "bash: a.out: command not found" (without the quotes) Also worth mentioning is that i... (5 Replies)
Discussion started by: hito
5 Replies

2. Shell Programming and Scripting

Running shell script in Cygwin terminal

I am new to shell scripting. I tried to run a simple shell script using Cygwin terminal in Win XP env. The script I have written is as follows - #!/bin/bash a=5 ] && echo "true" || echo "false" But when I execute the script, getting some confusing error. The error I am getting are - ... (3 Replies)
Discussion started by: linux_learner
3 Replies

3. Windows & DOS: Issues & Discussions

Powershell Script Help

Need some help getting this script to work. can someone help. I am trying to create a script that moves log files to another location and only keeps 60 days worth. please see script I started but having issue getting to work.. $TODAY=GET-DATE GET-CHILDITEM C:\test\*.LOG | Where {... (9 Replies)
Discussion started by: freedavis
9 Replies

4. Shell Programming and Scripting

How to start powershell with shebang from windows/cygwin/bash?

I would like to the the windws8/cygwin/bash shebang feature to start a powershell script. I do a "chmod +x set-sound.ps1" and then at a bash prompt I do ./set-sound.ps1 The first line of ./set-sound.ps1 #!powershell.exe -ExecutionPolicy unrestricted The result is the result: ... (5 Replies)
Discussion started by: siegfried
5 Replies

5. Shell Programming and Scripting

Running q-shell commands( on IBM-i Series) from cygwin terminal (on windows)

I have cygwin installed on windows server and when I do echo $SHELL the output is /bin/bash I have created a ssh tunnel from this windows server through cygwin to ibm -i series which is running Q-shell. I am trying to invoke a utility wsadmin (used for scripting) on ibm-i from the... (12 Replies)
Discussion started by: gaurav99
12 Replies

6. Shell Programming and Scripting

Bash script - cygwin (powershell?) pull from GitHub API Parse JSON

All, Have a weird issue where i need to generate a report from GitHub monthly detailing user accounts and the last time they logged in. I'm using a windows box to do this (work issued) and would like to know if anyone has any experience scripting for GitAPI using windows / cygwin / powershell?... (9 Replies)
Discussion started by: ChocoTaco
9 Replies

7. Programming

Running python script in cygwin

I have python installed here on windows: C:\Python27 and can run a script from the command line but would rather use cygwin. $ cd "C:\Users\cmccabe\Desktop\annovar" cmccabe@DTV-L2231M5J /cygdrive/c/Users/cmccabe/Desktop/annovar $ python run_batch_job.py Traceback (most recent call last):... (3 Replies)
Discussion started by: cmccabe
3 Replies

8. Shell Programming and Scripting

Powershell script to monitor windows process

Hello Friend, I am not expert in power shell scripting. I nee custom powershell script which check if given process is running on windows machine or not. will use it in nagios to monitor that process. (0 Replies)
Discussion started by: ghpradeep
0 Replies

9. Shell Programming and Scripting

Execute powershell script with UNIX

Hi I have a powershell script which is checking whether a windows service is running (as shown below) function FuncCheckService { $ServiceName = 'pgsql-9.2' $arrService = Get-Service -Name $ServiceName if ($arrService.Status -eq 'Running') { Write-Output... (8 Replies)
Discussion started by: simpsa27
8 Replies

10. UNIX for Beginners Questions & Answers

powershell script to unix shell script conversion.

Here is a powershell script to use restful API to create ticket in our ticketing tool. Can anyone please convert it to a shell script sothat, I can run it in Unix servers, below is the code: $body = @{ Customer= ''test' Summary= 'test summary' Impact= '4-Minor/Localized' ... (2 Replies)
Discussion started by: pandeybhavesh18
2 Replies
BVRML(3pm)						User Contributed Perl Documentation						BVRML(3pm)

NAME
XRacer::BVRML - Parser for a tiny subset of VRML generated by Blender SYNOPSIS
use XRacer::BVRML; DESCRIPTION
This is a parser for a tiny subset of VRML generated by Blender, so called Blender-VRML or BVRML. In fact, this parser is by no means guaranteed to be able to parse everything that Blender could generate. I will add parsing capability to it as I see the need. "XRacer::BVRML" parses a Blender VRML file, and stores it in an internal world representation, which can be inspected and manipulated. "XRacer::BVRML" can also write out a C function containing GL commands which render this world object, and this function can then be used inside an XRacer track or craft file. CLASS METHODS
$world = XRacer::BVRML->parse ($filename [, $world]); This function parses a BVRML file called $filename, and generates a $world object. If the second optional $world parameter is given, then the BVRML file is parsed and the results are merged with the existing $world object. If the parsing fails, then this function will print an error message and return "undef". WORLD OBJECT METHODS
$nr_vertices = $world->nr_vertices; Return the total number of vertices in the world. $nr_faces = $world->nr_faces; Return the total number of faces in the world. @vertices = $world->vertices; Aggregate all vertices in the world, and return it as a list. @faces = $world->faces; Aggregate all faces in the world, and return it as a list. ($smallest_x, $largest_x, $smallest_y, $largest_y, $smallest_z, $largest_z) = $world->bbox; Return the bounding box (or bounding cuboid, to be more precise) of this world. $world->write_display_function ([name => $function_name,] [filehandle => $filehandle,] [decl => $decl]); Write out a C function containing GL calls which, when invoked, will display this world object. The C function is called $function_name and will be written to the file specified by the $filehandle. The function will be declared as "void function_name (void)" unless the $decl parameter is given, which gives the return declaration. The C function is suitable for directly linking into XRacer craft and track files. However, it requires some support. In particular, you will need to include the header file GL/gl.h, and probably xracer.h before the function. AUTHOR
Richard W.M. Jones, <rich@annexia.org> COPYRIGHT
XRacer is copyright (C) 1999-2000 Richard W.M. Jones (rich@annexia.org) and other contributors listed in the AUTHORS file. SEE ALSO
perl(1), xracer(6). perl v5.14.2 2000-01-07 BVRML(3pm)
All times are GMT -4. The time now is 08:06 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy