From 0272f812daf187e8fa8fb297d08f3e4cdc636e7d Mon Sep 17 00:00:00 2001
From: Reinier Balt
Date: Tue, 4 Aug 2009 09:54:45 +0200
Subject: [PATCH] Add the ability to integrate your tracks installation as a
Gmail Gadget. Code was contributed by GTDify.com. Thanks!
see http://www.getontracks.org/forums/viewthread/434/
---
app/controllers/integrations_controller.rb | 4 +
app/views/integrations/index.html.erb | 176 ++++++++++++---------
app/views/layouts/standard.html.erb | 2 +-
public/stylesheets/standard.css | 13 +-
4 files changed, 117 insertions(+), 78 deletions(-)
diff --git a/app/controllers/integrations_controller.rb b/app/controllers/integrations_controller.rb
index 26f5f99d..ebf6a78c 100644
--- a/app/controllers/integrations_controller.rb
+++ b/app/controllers/integrations_controller.rb
@@ -32,4 +32,8 @@ class IntegrationsController < ApplicationController
render :layout => false
end
+ def google_gadget
+ render :layout => false, :content_type => Mime::XML
+ end
+
end
diff --git a/app/views/integrations/index.html.erb b/app/views/integrations/index.html.erb
index be2a5a0c..9d468228 100644
--- a/app/views/integrations/index.html.erb
+++ b/app/views/integrations/index.html.erb
@@ -1,27 +1,22 @@
<% has_contexts = !current_user.contexts.empty? -%>
Integrations
-
Tracks can be integrated with a number of other tools... whatever it takes to help you get things done! This page has information on setting up some of these. Not all of these are applicable to all platforms, and some require more technical knowledge than others. See also <%= link_to "developer documentation for Tracks' REST API", url_for(:action => 'rest_api') %>.
-
Contents:
-
+
Tracks can be integrated with a number of other tools...
+ whatever it takes to help you get things done!
+ This page has information on setting up some of these.
+ Not all of these are applicable to all platforms, and some require more
+ technical knowledge than others.
+ See also <%= link_to "developer documentation for Tracks' REST API", url_for(:action => 'rest_api') %>.
-If Tracks is running on the same server as your mail server, you can use the integrated mail handler built into tracks. Steps to set it up:
-
-
Go to <%= link_to "Preferences", preferences_url %> and set your "From email" and "default email context" for todos sent in via email (which could come from an SMS message)
-
In sendmail/qmail/postfix/whatever, set up an email address alias to pipe messages to
/PATH/TO/RUBY/ruby /PATH/TO/TRACKS/script/runner -e production 'MessageGateway.receive(STDIN.read)'
-
Send an email to your newly configured address!
-
-You can also use the Rich Todo API to send in tasks like "do laundry @ Home" or "Call Bill > project X". The subject of the message will fill description, context, and project, while the body will populate the tasks's note.
+
Copy the Applescript below to the clipboard.
+
+
+
+
Open Script Editor and paste the script into a new document.
+
Compile and save the script. Run it as necessary.
+
<% else %>
You do not have any context yet. The script will be available after you add your first context
<% end %>
@@ -54,23 +49,23 @@ You can also use the Rich Todo API to send in tasks like "do laundry @ Home" or
This script takes the sender and subject of the selected email(s) in Mail and creates a new action for each one, with the description, "Email [sender] about [subject]". The description gets truncated to 100 characters (the validation limit for the field) if it is longer than that. It also has Growl notifications if you have Growl installed.
Copy the Applescript below to the clipboard.
-
-
-
-
Open Script Editor and paste the script into a new document.
-
Compile and save the script as "Add to Tracks.scpt" in ~/Library/Application Support/Quicksilver/Actions/ (you may need to create the Actions directory)
-
Restart Quicksilver
-
Activate Quicksilver (Ctrl+Space by default)
-
Press "." to put quicksilver into text mode
-
Type the description of the next action you want to add
-
Press tab to switch to the action pane.
-
By typing or scrolling, choose the "Add to Tracks" action.
Copy the Applescript below to the clipboard.
+
+
+
+
Open Script Editor and paste the script into a new document.
+
Compile and save the script as "Add to Tracks.scpt" in ~/Library/Application Support/Quicksilver/Actions/ (you may need to create the Actions directory)
+
Restart Quicksilver
+
Activate Quicksilver (Ctrl+Space by default)
+
Press "." to put quicksilver into text mode
+
Type the description of the next action you want to add
+
Press tab to switch to the action pane.
+
By typing or scrolling, choose the "Add to Tracks" action.
+
<% else %>
You do not have any context yet. The script will be available after you add your first context
<% end %>
@@ -115,3 +110,38 @@ You can also use the Rich Todo API to send in tasks like "do laundry @ Home" or
You can of course use other text <%= link_to 'feeds provided by Tracks', feeds_path %> -- why not email a list of next actions in a particular project to a group of colleagues who are working on the project?
+
+
+
Integrated email/SMS receiver
+
+ If Tracks is running on the same server as your mail server, you can use the integrated mail handler built into tracks. Steps to set it up:
+
+
Go to <%= link_to "Preferences", preferences_url %> and set your "From email" and "default email context" for todos sent in via email (which could come from an SMS message)
+
In sendmail/qmail/postfix/whatever, set up an email address alias to pipe messages to
/PATH/TO/RUBY/ruby /PATH/TO/TRACKS/script/runner -e production 'MessageGateway.receive(STDIN.read)'
+
Send an email to your newly configured address!
+
+
You can also use the Rich Todo API to send in tasks like "do laundry @ Home"
+ or "Call Bill > project X". The subject of the message will fill description,
+ context, and project, while the body will populate the tasks's note.
+
+
+
+
Add Tracks as a Google Gmail gadget
+
+ You can now manage your projects/actions inside Gmail using Tracks Gmail Gadget.
+ Add Tracks Gmail gadget to the sidebar of Gmail and track your next actions
+ or add new action without explicitly open new browser tab for Tracks. Steps to set it up:
+
+
+
Sign in to Gmail and click Settings in the top right of your Gmail page. In Gmail setting page, click Labs tab
+
Enable the "Add any gadget by URL" feature. You will find it at bottom of the list. Select Enable radio button and click Save Changes button.
+
Now you can see Gadgets tab added to Gmail Settings. Go to the Gadgets tab
+
Paste following link to the Add a gadget by its URL: and then click Add button:
+
<%= integrations_url + "/google_gadget" %>
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/app/views/layouts/standard.html.erb b/app/views/layouts/standard.html.erb
index 651691e7..4057d367 100644
--- a/app/views/layouts/standard.html.erb
+++ b/app/views/layouts/standard.html.erb
@@ -81,7 +81,7 @@
<%= render_flash %>
-