<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<atom:link href="http://dev1galaxy.org/extern.php?action=feed&amp;tid=2739&amp;type=rss" rel="self" type="application/rss+xml" />
		<title><![CDATA[Dev1 Galaxy Forum / run script after suspend]]></title>
		<link>http://dev1galaxy.org/viewtopic.php?id=2739</link>
		<description><![CDATA[The most recent posts in run script after suspend.]]></description>
		<lastBuildDate>Tue, 19 Mar 2019 06:13:39 +0000</lastBuildDate>
		<generator>FluxBB</generator>
		<item>
			<title><![CDATA[Re: run script after suspend]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=14964#p14964</link>
			<description><![CDATA[<p>Thank you very much for your insight. </p><p>I tried to change the name of the file, but it didn’t help. However, I think that I found the confusion. If I suspend the computer using the log out option in the xfce menu, or if I directly use the command line using xfce tools (xfce4-session-logout –suspend), then the script won’t be effective. However, if I run the pm-suspend command, then the script will work. </p><p>I looked a discussion in the xfce forum, and it seems to be normal behaviour <a href="https://forum.xfce.org/viewtopic.php?id=9760" rel="nofollow">https://forum.xfce.org/viewtopic.php?id=9760</a>. It seems that there is a way around that when using systemd, but I am unsure if it is possible to do something similar without it.</p>]]></description>
			<author><![CDATA[dummy@example.com (hothr)]]></author>
			<pubDate>Tue, 19 Mar 2019 06:13:39 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=14964#p14964</guid>
		</item>
		<item>
			<title><![CDATA[Re: run script after suspend]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=14962#p14962</link>
			<description><![CDATA[<p>A quick review of the code suggests that &quot;local&quot; specializations should rather reside in <span class="bbc">/etc/pm/sleep.d</span> than <span class="bbc">/usr/lib/pm-utils/sleep.d</span>, but that&#039;s not the problem here (since the latter is the &quot;program&quot; place for such scripts). However, the order is important. Scripts run in the order of their filenames, sorted as per <span class="bbc">sort</span> (with LC_COLLATE=C).</p><p>Thus, the first check is where in the list of sleep scripts your script ends up, and then you need to determine whether that&#039;s the wrong place, and if so, rename it so as to have it run earlier or later. Note, if I understand it right, the scripts are run in the sort order before suspending, and reverse to that when resuming.</p><p>btw, it&#039;s good to append a <span class="bbc">true</span> to your script, to make it always return success instead of returning whatever the <span class="bbc">amixer</span> command returns.</p>]]></description>
			<author><![CDATA[dummy@example.com (ralph.ronnquist)]]></author>
			<pubDate>Mon, 18 Mar 2019 22:45:06 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=14962#p14962</guid>
		</item>
		<item>
			<title><![CDATA[run script after suspend]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=14958#p14958</link>
			<description><![CDATA[<p>Hi there, </p><p>I try to run a command before/after suspending the computer, but I am not able to do so, and I was wondering it someone can help me with that. In short, one of the things that I would like to be able to do, is to control the headphone sound after suspending the computer.&#160; In the past, with gentoo based distribution using openRC, I would create a file called sound in /usr/lib/pm-utils/sleep.d, make it executable (chmod&#160; &#160;+x) , and write :</p><div class="quotebox"><blockquote><div><p>#!/bin/sh</p><p>case &quot;$1&quot; in<br />&#160; &#160; resume)<br />&#160; &#160; &#160; &#160; amixer --card 1 sset Headphone 100%<br />esac</p></div></blockquote></div><p>However, with Devuan, using SysV (and xfce), it won’t work. I have tried the amixer --card 1 sset Headphone 100% command, and everything is working just fine, so I am pretty sure that, either my script is incorrect, or it is not at the right place. </p><p>Any help would be appreciated.</p>]]></description>
			<author><![CDATA[dummy@example.com (hothr)]]></author>
			<pubDate>Mon, 18 Mar 2019 18:27:26 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=14958#p14958</guid>
		</item>
	</channel>
</rss>
