Dennis Craven | 3 Dec 17:54 2006
Picon

Wyrd's Quick Add Feature from the CLI?

Hello,

This is the unofficial mailing list for Wyrd as I understand it. If
not, my apologies.

Would it be possible to have, for example, a -q switch for wyrd so that this:

$ wyrd -q "Drop of package at 3pm"

could add a reminder straight from the command line without actually
starting the wyrd interface? It's trivial to add vanilla remind
reminders from the command line as it is, but I think it would be nice
to take advantage of wyrd's quick add parser to do this. I had a look
at the source thinking I could patch it myself, but saw it was written
in OCaml, which I've not learned yet :).

Cheers,
~djc

Paul Pelzl | 3 Dec 19:45 2006
Picon

Re: Wyrd's Quick Add Feature from the CLI?

On Sun, Dec 03, 2006 at 11:54:11AM -0500, Dennis Craven wrote:
> Would it be possible to have, for example, a -q switch for wyrd so that this:
> 
> $ wyrd -q "Drop of package at 3pm"
> 
> could add a reminder straight from the command line without actually
> starting the wyrd interface? 

Yeah, that shouldn't be too difficult.  I'll see what I can do.

Paul

Kyle Sexton | 5 Dec 02:34 2006

Re: Wyrd's Quick Add Feature from the CLI?

On Sun, Dec 03, 2006 at 01:45:45PM -0500, Paul Pelzl wrote:
> On Sun, Dec 03, 2006 at 11:54:11AM -0500, Dennis Craven wrote:
> > Would it be possible to have, for example, a -q switch for wyrd so that this:
> > 
> > $ wyrd -q "Drop of package at 3pm"
> > 
> > could add a reminder straight from the command line without actually
> > starting the wyrd interface? 
> 
> Yeah, that shouldn't be too difficult.  I'll see what I can do.
> 
> Paul
> 
> 
> _______________________________________________
> Remind-fans mailing list
> Remind-fans@...
> http://lists.whatexit.org/mailman/listinfo/remind-fans

One of my projects is to have mutt automatically add from an Outlook invite
to my reminder file.  Having the quick add via command line would make this
quite a bit easier. :)

--
Kyle Sexton

Mike Harris | 12 Dec 20:43 2006

Remind & Anacron & Non-Root-Owned Files - HAWLP!

I've got a bit of a hardcore Unix question that is tangentially related to Remind.

I have been trying to set up the daily e-mailing of Remind output -- in the form of a 'daily' calendar and a
two-week calendar -- to me.  The latest incarnation involves 'anacron,' a variation on cron that accounts
for when a system is sleeping (something cron doesn't account for).

However, the problem seems to be that when Remind is run by anacron, it is run as root, creating an empty
message body.  The message is:

> SECURITY: Won't read non-root-owned file when running as root!
> Error reading file /Users/mharris/.reminders: Can't open file
> Null message body; hope that's ok

If anyone has any thoughts along this line as to what I might be able to do, I'd appreciate it.  I'm not
extremely expert in Unix, although I have a passing knowledge.  I do know that anacron does not have the "run
as user" column that cron does.

Anyway, if anyone has thoughts, I'd appreciate it.

Mike

Serge Arsenault | 15 Dec 16:43 2006
Picon

Re: Remind & Anacron & Non-Root-Owned Files - HAWLP!

Hi Mike,

One way of doing this is to use the su command when invoking the remind
command and specifying which user it should be run as:

su <username> -c "remind <remind args>"

This will effectively run the remind command as if it were run by
username.

Serge

On Tue, 2006-12-12 at 14:43 -0500, Mike Harris wrote:
> I've got a bit of a hardcore Unix question that is tangentially related to Remind.
> 
> I have been trying to set up the daily e-mailing of Remind output -- in the form of a 'daily' calendar and a
two-week calendar -- to me.  The latest incarnation involves 'anacron,' a variation on cron that accounts
for when a system is sleeping (something cron doesn't account for).
> 
> However, the problem seems to be that when Remind is run by anacron, it is run as root, creating an empty
message body.  The message is:
> 
> > SECURITY: Won't read non-root-owned file when running as root!
> > Error reading file /Users/mharris/.reminders: Can't open file
> > Null message body; hope that's ok
> 
> If anyone has any thoughts along this line as to what I might be able to do, I'd appreciate it.  I'm not
extremely expert in Unix, although I have a passing knowledge.  I do know that anacron does not have the "run
as user" column that cron does.
> 
(Continue reading)

T E Schmitz | 15 Dec 16:41 2006
Picon

Re: Remind & Anacron & Non-Root-Owned Files - HAWLP!

Mike Harris wrote:
> I've got a bit of a hardcore Unix question that is tangentially related to Remind.
> 
> I have been trying to set up the daily e-mailing of Remind output -- in the form of a 'daily' calendar and a
two-week calendar -- to me.  The latest incarnation involves 'anacron,' a variation on cron that accounts
for when a system is sleeping (something cron doesn't account for).
> 
> However, the problem seems to be that when Remind is run by anacron, it is run as root, creating an empty
message body.  The message is:

I have just set this up myself:

You need to run anacron under your user using your own anacrontab and 
spool directory for anacron's timestamp files:

anacron -S $HOME/cron/spool -t $HOME/cron/anacrontab

I run anacron from my .bashrc. This means it gets executed for every 
login. On the other hand, it doesn't matter as anacron will only run the 
job at the intervals specified in your anacrontab.

I keep all the anacron + cron stuff in $HOME/cron.

The actual job itself is a shell script, which pipes remind's output 
into mail.

--

-- 

Best Regards,

(Continue reading)

Justin Alcorn | 15 Dec 21:41 2006
Picon

Re: Remind & Anacron & Non-Root-Owned Files - HAWLP!

Serge Arsenault wrote:
> Hi Mike,
> 
> One way of doing this is to use the su command when invoking the remind
> command and specifying which user it should be run as:
> 
> su <username> -c "remind <remind args>"
> 
> This will effectively run the remind command as if it were run by
> username.
> 
> Serge

You'll want to make it

su - <user> -c "remind [args]"

the '-' makes sure that the task runs with the correct environment for 
the specified user.

Serge Arsenault | 18 Dec 14:49 2006
Picon

Re: Remind & Anacron & Non-Root-Owned Files - HAWLP!

Oops you are right Justin...a serious omission there. I usually work
under NetBSD and use '-l' instead of '-' since it seems a bit more
intuitive to me. I understand, however, that this option doesn't exist
with all variants of su (e.g. the stock one with Ubuntu).

On Fri, 2006-15-12 at 15:41 -0500, Justin Alcorn wrote:
> You'll want to make it
> 
> su - <user> -c "remind [args]"
> 
> the '-' makes sure that the task runs with the correct environment
> for 
> the specified user. 

Andrew Ho | 21 Dec 22:47 2006
Picon

displaying AT time

Hi,

I'm trying to get 'rem' to display the time of a reminder, such that if 
I have:

REM 1 Feb 2007 AT 09:00 MSG Meeting%

then the command 'rem 1 Feb 2007' will display:

09:00 Meeting

This is relatively trivial if I simply define the following:

FSET MSGPREFIX(x) trigtime() + " "

However, this chokes when I have an "all day" reminder (in other words, one 
where I don't define an AT).  It displays the last AT time that was set; I'd 
ideally like it not to display anything.

Any pointers would be greatly appreciated,
Andy
Paul Pelzl | 21 Dec 23:37 2006
Picon

Re: displaying AT time

On Thu, Dec 21, 2006 at 09:47:07PM +0000, Andrew Ho wrote:
> Hi,
> 
> I'm trying to get 'rem' to display the time of a reminder, such that if 
> I have:
> 
> REM 1 Feb 2007 AT 09:00 MSG Meeting%
> 
> then the command 'rem 1 Feb 2007' will display:
> 
> 09:00 Meeting
> 
> This is relatively trivial if I simply define the following:
> 
> FSET MSGPREFIX(x) trigtime() + " "
> 
> However, this chokes when I have an "all day" reminder (in other words, one 
> where I don't define an AT).  It displays the last AT time that was set; 
> I'd ideally like it not to display anything.
> 
> Any pointers would be greatly appreciated,

You might consider a different approach.  The "simple calendar" Remind
output ("rem -s") can provide the timestamps without any extra work on
your part.  You just need to reformat the calendar a bit before
displaying it.  Example:

   $ rem -s -b1 | grep `date +"%y/%m/%d"` | cut -d " " -f "6-"

Paul
(Continue reading)


Gmane