public inbox for cygwin-apps@cygwin.com
 help / color / mirror / Atom feed
* [ITP] nosleep 0.1.3-1
@ 2011-09-25 10:15 Andrew Schulman
  2011-09-27 18:33 ` Christopher Faylor
                   ` (4 more replies)
  0 siblings, 5 replies; 15+ messages in thread
From: Andrew Schulman @ 2011-09-25 10:15 UTC (permalink / raw)
  To: cygwin-apps

I'd like to package and maintain nosleep for Cygwin.  nosleep runs a
command while inhibiting the computer from sleeping or hibernating until
the command finishes executing.  By default nosleep just prevents the
computer from going to sleep during idle periods.  More aggressive options
are available to inhibit sleep or hibernation, but these come with warnings
and an onerous Disclaimer.

nosleep has been written originally for Cygwin, so it's not available in
any Linux distros and needs to be voted on.

Note that nosleep requires libargp, which is currently also in ITP for
Cygwin [1].

License:    GPLv3
Home page:  https://launchpad.net/nosleep
Author:     Andrew E. Schulman <andrex@alumni.utexas.net>

<setup.hint>
sdesc: "Run a command while inhibiting computer sleep or hibernation"
ldesc: "nosleep runs a command while inhibiting the computer from sleeping
or hibernating until the command finishes executing.  By default nosleep
just prevents the computer from going to sleep during idle periods.  More
aggressive options are available to inhibit sleep or hibernation, but
these come with warnings and an onerous Disclaimer."
category: Utils
requires: libargp
</setup.hint>

[1] http://cygwin.com/ml/cygwin-apps/2011-09/msg00071.html

wget \
 http://home.comcast.net/~andrex2/cygwin/nosleep/setup.hint \
 http://home.comcast.net/~andrex2/cygwin/nosleep/nosleep-0.1.3-1.tar.bz2 \

http://home.comcast.net/~andrex2/cygwin/nosleep/nosleep-0.1.3-1-src.tar.bz2

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [ITP] nosleep 0.1.3-1
  2011-09-25 10:15 [ITP] nosleep 0.1.3-1 Andrew Schulman
@ 2011-09-27 18:33 ` Christopher Faylor
  2011-09-27 19:05   ` Reini Urban
  2011-09-27 19:18 ` Charles Wilson
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 15+ messages in thread
From: Christopher Faylor @ 2011-09-27 18:33 UTC (permalink / raw)
  To: cygwin-apps

On Sun, Sep 25, 2011 at 06:15:37AM -0400, Andrew Schulman wrote:
>I'd like to package and maintain nosleep for Cygwin.  nosleep runs a
>command while inhibiting the computer from sleeping or hibernating until
>the command finishes executing.  By default nosleep just prevents the
>computer from going to sleep during idle periods.  More aggressive options
>are available to inhibit sleep or hibernation, but these come with warnings
>and an onerous Disclaimer.

+1

cgf

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [ITP] nosleep 0.1.3-1
  2011-09-27 18:33 ` Christopher Faylor
@ 2011-09-27 19:05   ` Reini Urban
  0 siblings, 0 replies; 15+ messages in thread
From: Reini Urban @ 2011-09-27 19:05 UTC (permalink / raw)
  To: cygwin-apps

On Tue, Sep 27, 2011 at 1:33 PM, Christopher Faylor wrote:
> On Sun, Sep 25, 2011 at 06:15:37AM -0400, Andrew Schulman wrote:
>>I'd like to package and maintain nosleep for Cygwin.  nosleep runs a
>>command while inhibiting the computer from sleeping or hibernating until
>>the command finishes executing.  By default nosleep just prevents the
>>computer from going to sleep during idle periods.  More aggressive options
>>are available to inhibit sleep or hibernation, but these come with warnings
>>and an onerous Disclaimer.
>
> +1

+1
-- 
Reini

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [ITP] nosleep 0.1.3-1
  2011-09-25 10:15 [ITP] nosleep 0.1.3-1 Andrew Schulman
  2011-09-27 18:33 ` Christopher Faylor
@ 2011-09-27 19:18 ` Charles Wilson
  2011-09-28 13:53   ` Buchbinder, Barry (NIH/NIAID) [E]
  2011-09-27 21:16 ` Chris Sutcliffe
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 15+ messages in thread
From: Charles Wilson @ 2011-09-27 19:18 UTC (permalink / raw)
  To: CygWin-Apps

On 9/25/2011 6:15 AM, Andrew Schulman wrote:
> nosleep has been written originally for Cygwin, so it's not available in
> any Linux distros and needs to be voted on.

+1

--
Chuck

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [ITP] nosleep 0.1.3-1
  2011-09-25 10:15 [ITP] nosleep 0.1.3-1 Andrew Schulman
  2011-09-27 18:33 ` Christopher Faylor
  2011-09-27 19:18 ` Charles Wilson
@ 2011-09-27 21:16 ` Chris Sutcliffe
  2011-09-28 15:31 ` Christian Franke
  2011-09-30 10:01 ` [ITP] nosleep 0.1.3-1 (needs GTG) Andrew Schulman
  4 siblings, 0 replies; 15+ messages in thread
From: Chris Sutcliffe @ 2011-09-27 21:16 UTC (permalink / raw)
  To: cygwin-apps

On 25 September 2011 06:15, Andrew Schulman wrote:
> nosleep has been written originally for Cygwin, so it's not available in
> any Linux distros and needs to be voted on.

+1

Chris

-- 
Chris Sutcliffe
http://emergedesktop.org
http://www.google.com/profiles/ir0nh34d

^ permalink raw reply	[flat|nested] 15+ messages in thread

* RE: [ITP] nosleep 0.1.3-1
  2011-09-27 19:18 ` Charles Wilson
@ 2011-09-28 13:53   ` Buchbinder, Barry (NIH/NIAID) [E]
  2011-09-28 16:27     ` Andrew Schulman
  0 siblings, 1 reply; 15+ messages in thread
From: Buchbinder, Barry (NIH/NIAID) [E] @ 2011-09-28 13:53 UTC (permalink / raw)
  To: CygWin-Apps

On 9/25/2011 6:15 AM, Andrew Schulman wrote:
> nosleep has been written originally for Cygwin, so it's not available 
> in any Linux distros and needs to be voted on.

Just wondering ...

Since "nosleep has been written originally for Cygwin", might it make
sense to add this to cygutils ("A collection of simple utilities")?

Just a thought - not a request.

- Barry
  Disclaimer: Statements made herein are not made on behalf of NIAID.

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [ITP] nosleep 0.1.3-1
  2011-09-25 10:15 [ITP] nosleep 0.1.3-1 Andrew Schulman
                   ` (2 preceding siblings ...)
  2011-09-27 21:16 ` Chris Sutcliffe
@ 2011-09-28 15:31 ` Christian Franke
  2011-09-30 10:01 ` [ITP] nosleep 0.1.3-1 (needs GTG) Andrew Schulman
  4 siblings, 0 replies; 15+ messages in thread
From: Christian Franke @ 2011-09-28 15:31 UTC (permalink / raw)
  To: cygwin-apps

Andrew Schulman wrote:
> nosleep has been written originally for Cygwin, so it's not available in
> any Linux distros and needs to be voted on.
>
>    

+1

Christian

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [ITP] nosleep 0.1.3-1
  2011-09-28 13:53   ` Buchbinder, Barry (NIH/NIAID) [E]
@ 2011-09-28 16:27     ` Andrew Schulman
  2011-10-09 19:46       ` Reini Urban
  0 siblings, 1 reply; 15+ messages in thread
From: Andrew Schulman @ 2011-09-28 16:27 UTC (permalink / raw)
  To: cygwin-apps

> On 9/25/2011 6:15 AM, Andrew Schulman wrote:
> > nosleep has been written originally for Cygwin, so it's not available 
> > in any Linux distros and needs to be voted on.
> 
> Just wondering ...
> 
> Since "nosleep has been written originally for Cygwin", might it make
> sense to add this to cygutils ("A collection of simple utilities")?

It doesn't matter to me either way.  My guess is that since nosleep is brand
new, people might want some time to try it out and gain confidence that it works
as advertised, before adopting it as a standard utility.

A few other considerations:

* nosleep currently depends on libargp, which cygutils probably doesn't want to
do.  That could be worked around by importing the argp source into nosleep, but
I don't know if cygutils wants to increase its size by that much.

* Although it's currently only implemented for Cygwin, nosleep has big (waking)
dreams of being implemented on other platforms too.  So it may not stay a
Cygwin-only utility.  Not sure if that matters.

Andrew.

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [ITP] nosleep 0.1.3-1 (needs GTG)
  2011-09-25 10:15 [ITP] nosleep 0.1.3-1 Andrew Schulman
                   ` (3 preceding siblings ...)
  2011-09-28 15:31 ` Christian Franke
@ 2011-09-30 10:01 ` Andrew Schulman
  2011-09-30 14:00   ` Charles Wilson
  4 siblings, 1 reply; 15+ messages in thread
From: Andrew Schulman @ 2011-09-30 10:01 UTC (permalink / raw)
  To: cygwin-apps

> I'd like to package and maintain nosleep for Cygwin.  nosleep runs a
> command while inhibiting the computer from sleeping or hibernating until
> the command finishes executing.

Thanks for voting everyone.  Would someone now please review the packaging?
The package is small - just one exectable and 6 doc files.

I've prepared a new release that corrects the source URL in the cygport
script.  URLs are below.

Thanks,
Andrew.

wget \
 http://home.comcast.net/~andrex2/cygwin/nosleep/setup.hint \
 http://home.comcast.net/~andrex2/cygwin/nosleep/nosleep-0.1.3-2.tar.bz2 \
 http://home.comcast.net/~andrex2/cygwin/nosleep/nosleep-0.1.3-2-src.tar.bz2
 

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [ITP] nosleep 0.1.3-1 (needs GTG)
  2011-09-30 10:01 ` [ITP] nosleep 0.1.3-1 (needs GTG) Andrew Schulman
@ 2011-09-30 14:00   ` Charles Wilson
  2011-09-30 15:57     ` Andrew Schulman
  0 siblings, 1 reply; 15+ messages in thread
From: Charles Wilson @ 2011-09-30 14:00 UTC (permalink / raw)
  To: CygWin-Apps

On 9/30/2011 6:00 AM, Andrew Schulman wrote:
>> I'd like to package and maintain nosleep for Cygwin.  nosleep runs a
>> command while inhibiting the computer from sleeping or hibernating until
>> the command finishes executing.
> 
> Thanks for voting everyone.  Would someone now please review the packaging?
> The package is small - just one exectable and 6 doc files.

Packaging is GTG.  I didn't check the application's functionality.

Since you don't have a test suite, you might want to define a src_test
function in the cygport:

src_test() {
	:
}


--
Chuck

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [ITP] nosleep 0.1.3-1 (needs GTG)
  2011-09-30 14:00   ` Charles Wilson
@ 2011-09-30 15:57     ` Andrew Schulman
  2011-09-30 17:13       ` Reini Urban
  0 siblings, 1 reply; 15+ messages in thread
From: Andrew Schulman @ 2011-09-30 15:57 UTC (permalink / raw)
  To: cygwin-apps

> Packaging is GTG.

Thanks.

>  I didn't check the application's functionality.

Right.  Unfortunately there's no fast or easy way to do that.  You have to run a
command that takes longer than your idle sleep timer, for example, and check
that the machine doesn't go to sleep.  I have done that and verified that each
of the options works as described, at least on my Windows 7 laptop.  But as I
describe in the man page, it's just hard to completely stop a host from going to
sleep, so it's always going to be hard to completely test that nosleep is
working as intended.

> Since you don't have a test suite, you might want to define a src_test
> function in the cygport:
> 
> src_test() {
> 	:
> }

OK, I'll do that.  

Package uploaders:  please wait for an RFU for nosleep 0.1.3-3.

Maybe in time I can develop a proper test suite, but it will always be a bit
labor-intensive.

Andrew.

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [ITP] nosleep 0.1.3-1 (needs GTG)
  2011-09-30 15:57     ` Andrew Schulman
@ 2011-09-30 17:13       ` Reini Urban
  2011-09-30 19:57         ` Andrew Schulman
  0 siblings, 1 reply; 15+ messages in thread
From: Reini Urban @ 2011-09-30 17:13 UTC (permalink / raw)
  To: cygwin-apps

On Fri, Sep 30, 2011 at 10:57 AM, Andrew Schulman wrote:
>>  I didn't check the application's functionality.
>
> Right.  Unfortunately there's no fast or easy way to do that.  You have to run a
> command that takes longer than your idle sleep timer, for example, and check
> that the machine doesn't go to sleep.  I have done that and verified that each
> of the options works as described, at least on my Windows 7 laptop.  But as I
> describe in the man page, it's just hard to completely stop a host from going to
> sleep, so it's always going to be hard to completely test that nosleep is
> working as intended.

> Maybe in time I can develop a proper test suite, but it will always be a bit
> labor-intensive.

I would like to see a test with simple command lines without checking
the nosleep behavior. Just to check if can correctly pass the command
with options with proper quoting.
-- 
Reini Urban
http://cpanel.net/   http://www.perl-compiler.org/

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [ITP] nosleep 0.1.3-1 (needs GTG)
  2011-09-30 17:13       ` Reini Urban
@ 2011-09-30 19:57         ` Andrew Schulman
  0 siblings, 0 replies; 15+ messages in thread
From: Andrew Schulman @ 2011-09-30 19:57 UTC (permalink / raw)
  To: cygwin-apps

> I would like to see a test with simple command lines without checking
> the nosleep behavior. Just to check if can correctly pass the command
> with options with proper quoting.

OK, this is a good idea.  It's a first functional test.  So I created a new
release upstream, 0.1.4, containing a new test directory and a 'make test' 
target that runs all of the scripts there.

At present there's one test.  It runs a helper script that just prints the 
number and content of its command line arguments.  The test runs the helper 
with some command line arguments:

helper/args.sh arg1 --arg2 - "arg 4"

It runs that with and without nosleep, compares the results, and fails 
noisily if they're different.

'cygport nosleep-0.1.4-1 test' now runs the functional tests from upstream, 
specifically the argument check.  It succeeds for me.

Thanks for the suggestion.
Andrew.

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [ITP] nosleep 0.1.3-1
  2011-09-28 16:27     ` Andrew Schulman
@ 2011-10-09 19:46       ` Reini Urban
  2011-10-11 15:02         ` Andrew Schulman
  0 siblings, 1 reply; 15+ messages in thread
From: Reini Urban @ 2011-10-09 19:46 UTC (permalink / raw)
  To: cygwin-apps

>> On 9/25/2011 6:15 AM, Andrew Schulman wrote:
>> > nosleep has been written originally for Cygwin, so it's not available
>> > in any Linux distros and needs to be voted on.

And now I'd really need it for MacOSX.
Let's see if I'll have enough tuits next week.
-- 
Reini Urban
http://cpanel.net/   http://www.perl-compiler.org/

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [ITP] nosleep 0.1.3-1
  2011-10-09 19:46       ` Reini Urban
@ 2011-10-11 15:02         ` Andrew Schulman
  0 siblings, 0 replies; 15+ messages in thread
From: Andrew Schulman @ 2011-10-11 15:02 UTC (permalink / raw)
  To: cygwin-apps

> >> On 9/25/2011 6:15 AM, Andrew Schulman wrote:
> >> > nosleep has been written originally for Cygwin, so it's not available
> >> > in any Linux distros and needs to be voted on.
> 
> And now I'd really need it for MacOSX.
> Let's see if I'll have enough tuits next week.

I have no experience with OS X, so I can't directly comment on that.  But
if there's a Cocoa or Darwin API that allows you to do things like check
whether AC power is on and keep the computer from going into idle sleep,
then it might be quite easy to port nosleep to OS X.  It's a small program.

For details please see the nosleep project page [1].  I'd like to see
nosleep ported to other platforms, and would be glad to discuss that with
you - maybe in the bug tracker for nosleep, since this is OT here.

A caution:  Being a Linux user, I looked into how one would implement
nosleep in Linux.  From what I can tell, chaos reigns there.  Although ACPI
would seem to be a likely API for it, the way people have been doing it in
practice is desktop-specific with a lot of ugly special cases.  I'm
thinking of Caffeine [2] in particular.  In OS X though, I'd expect things
to be more orderly.

[1] https://launchpad.net/nosleep
[2] https://launchpad.net/caffeine

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2011-10-11 15:02 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-09-25 10:15 [ITP] nosleep 0.1.3-1 Andrew Schulman
2011-09-27 18:33 ` Christopher Faylor
2011-09-27 19:05   ` Reini Urban
2011-09-27 19:18 ` Charles Wilson
2011-09-28 13:53   ` Buchbinder, Barry (NIH/NIAID) [E]
2011-09-28 16:27     ` Andrew Schulman
2011-10-09 19:46       ` Reini Urban
2011-10-11 15:02         ` Andrew Schulman
2011-09-27 21:16 ` Chris Sutcliffe
2011-09-28 15:31 ` Christian Franke
2011-09-30 10:01 ` [ITP] nosleep 0.1.3-1 (needs GTG) Andrew Schulman
2011-09-30 14:00   ` Charles Wilson
2011-09-30 15:57     ` Andrew Schulman
2011-09-30 17:13       ` Reini Urban
2011-09-30 19:57         ` Andrew Schulman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).