<project version="4">
<component name="ChangeListManager">
<list default="true" id="352ce63a-b52a-41a2-979b-becda7920939" name="Default" comment=".">
- <change beforePath="$PROJECT_DIR$/.htaccess" beforeDir="false" afterPath="$PROJECT_DIR$/.htaccess" afterDir="false" />
- <change beforePath="$PROJECT_DIR$/.idea/deployment.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/deployment.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
- <change beforePath="$PROJECT_DIR$/config/tv.php" beforeDir="false" afterPath="$PROJECT_DIR$/config/tv.php" afterDir="false" />
- <change beforePath="$PROJECT_DIR$/scripts/lib/domoticz.php" beforeDir="false" afterPath="$PROJECT_DIR$/scripts/lib/domoticz.php" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/composer.json" beforeDir="false" afterPath="$PROJECT_DIR$/composer.json" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/scripts/lib/ecomode.php" beforeDir="false" afterPath="$PROJECT_DIR$/scripts/lib/ecomode.php" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/scripts/lib/homeconnect.php" beforeDir="false" afterPath="$PROJECT_DIR$/scripts/lib/homeconnect.php" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/scripts/lib/http.php" beforeDir="false" afterPath="$PROJECT_DIR$/scripts/lib/http.php" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/scripts/lib/pc.php" beforeDir="false" afterPath="$PROJECT_DIR$/scripts/lib/pc.php" afterDir="false" />
<change beforePath="$PROJECT_DIR$/scripts/lib/ssh.php" beforeDir="false" afterPath="$PROJECT_DIR$/scripts/lib/ssh.php" afterDir="false" />
- <change beforePath="$PROJECT_DIR$/servers/startdaemon" beforeDir="false" afterPath="$PROJECT_DIR$/servers/startdaemon" afterDir="false" />
- <change beforePath="$PROJECT_DIR$/servers/startserver" beforeDir="false" />
- <change beforePath="$PROJECT_DIR$/servers/stopserver" beforeDir="false" />
+ <change beforePath="$PROJECT_DIR$/scripts/sleeppc.php" beforeDir="false" afterPath="$PROJECT_DIR$/scripts/sleeppc.php" afterDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
<option name="Make" enabled="true" />
</method>
</configuration>
- <configuration default="true" type="ArquillianJUnit" factoryName="" nameIsGenerated="true">
- <option name="arquillianRunConfiguration">
- <value>
- <option name="containerStateName" value="" />
- </value>
- </option>
- <option name="TEST_OBJECT" value="class" />
- <method v="2">
- <option name="Make" enabled="true" />
- </method>
- </configuration>
<configuration default="true" type="ArquillianTestNG" factoryName="">
<option name="arquillianRunConfiguration">
<value>
<workItem from="1622185202332" duration="1711000" />
<workItem from="1622440150420" duration="1374000" />
<workItem from="1622659686189" duration="138000" />
- <workItem from="1622659989891" duration="3179000" />
- </task>
- <task id="LOCAL-00440" summary=".">
- <created>1611655420798</created>
- <option name="number" value="00440" />
- <option name="presentableId" value="LOCAL-00440" />
- <option name="project" value="LOCAL" />
- <updated>1611655420798</updated>
+ <workItem from="1622659989891" duration="3855000" />
+ <workItem from="1622676912583" duration="2362000" />
</task>
<task id="LOCAL-00441" summary=".">
<created>1611656702791</created>
<option name="project" value="LOCAL" />
<updated>1622441173734</updated>
</task>
- <option name="localTasksCounter" value="489" />
+ <task id="LOCAL-00489" summary=".">
+ <created>1622664420441</created>
+ <option name="number" value="00489" />
+ <option name="presentableId" value="LOCAL-00489" />
+ <option name="project" value="LOCAL" />
+ <updated>1622664420442</updated>
+ </task>
+ <option name="localTasksCounter" value="490" />
<servers />
</component>
<component name="TypeScriptGeneratedFilesManager">
setState($s, '1');
}
-function sleepPC($device)
+function sleepPC($device,$force=false)
{
$s = 'device_' . $device . '_awake';
- if (getState($s) == '0') {
+ if (!$force && getState($s) == '0') {
echo 'already sleeping ' . $device . ' :: ' . $s;
return;
}
setState($s, '0');
- $res = sshCommand('"C:\Program Files\Scripts\sleep.bat"', $device, false);
+ $res = sshCommand('"C:\Program Files\Scripts\sleep.bat"', $device, true,true);
setState($s, '0');
return $res;
}
function pcScreensProfile($profile, $device)
{
- sshCommand('"C:\Program Files (x86)\DisplayFusion\DisplayFusionCommand.exe" -monitorloadprofile "' . $profile . '"', $device, false,true);
+ sshCommand('"C:\Program Files (x86)\DisplayFusion\DisplayFusionCommand.exe" -monitorloadprofile "' . $profile . '"', $device, false, true);
}
\ No newline at end of file
}
$user = $sudo ? 'root' : $d['user'];
//if (getState('device_' . $device . '_awake') == '1') {
+ print_r($d);
$ssh[$instance_key] = ssh2_connect($d['host'], 22);
if ($ssh[$instance_key]) {
if (!ssh2_auth_password($ssh[$instance_key], $user, $d['password'])) {
function sshRunCommand($command, $device = null, $blocking = true, $sudo = false)
{
$ssh = getSSHInstance($device, $sudo);
+ print_r($ssh);
if ($ssh) {
$stream = @ssh2_exec($ssh, $command);
if (!$stream) {