Make a few more targets translatable. Tracks should now be pretty close to fully translatable.

This commit is contained in:
Jyri-Petteri Paloposki 2021-01-11 00:15:44 +02:00
parent f2abb970ed
commit 971ef477e5
21 changed files with 457 additions and 403 deletions

View file

@ -1,51 +0,0 @@
<% has_contexts = !current_user.contexts.empty? -%>
<h1>Integration</h1>
<p>Tracks kann mit verschiedenen Werkzeugen zusammenarbeiten...
was immer Sie brauchen, um Ihre Aufgaben zu erledigen!
Auf dieser Seite finden Sie Informationen, um einige dieser Werkzeuge einzurichten.
Diese Beispiele sind nicht unbedingt auf Ihre Umgebung anwendbar oder bed&uuml;rfen mehr
technisches Wissen als andere.
Weitere Informationen finden Sie in der <%= link_to "Entwickler Documentation der Tracks' REST API", url_for(:action => 'rest_api') %> (englisch).</p>
<br/><p>Inhalt:</p>
<ul>
<li><a href="#email-cron-section">Anstehende Aufgaben automatisch sich via E-Mail zusenden lassen</a></li>
<li><a href="#message_gateway">Tracks mit einem Mail-Server integrieren, um Aufgaben via E-Mail zu erstellen</a></li>
</ul><br/>
<p>Sie haben weitere Beispiele?
<a href="http://www.getontracks.org/forums/viewforum/10/" title="Tracks | Tips and Tricks">Berichten Sie uns
in unserem Tipps&amp;Tricks Forum</a>, damit wir es f&uuml;r die n&auml;chsten Versionen ber&uuml;cksichtigen k&ouml;nnen.
</p>
<a name="email-cron-section"> </a>
<h2>Automatically Email Yourself Upcoming Actions</h2>
<p>If you enter the following entry to your crontab, you will receive email every day around 5 AM with a list of the upcoming actions which are due within the next 7 days.</p>
<textarea id="cron" name="cron">0 5 * * * /usr/bin/curl -0 "<%= root_url %>todos.txt?due=6&token=<%= current_user.token %>" | /usr/bin/mail -e -s 'Tracks actions due in the next 7 days' youremail@yourdomain.com</textarea>
<p>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?</p>
<a name="message_gateway"> </a>
<h2>Integrated email/SMS receiver</h2>
<p>
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:
</p>
<ul>
<li>Go to <%= link_to t('layouts.navigation.preferences'), preferences_url %> and
set your "<%= Preference.human_attribute_name('sms_email') %>" and
"<%= Preference.human_attribute_name('sms_context') %>" for todos sent in
via email (which could come from an SMS message)</li>
<li>In sendmail/qmail/postfix/whatever, set up an email address
alias to pipe messages to <pre>/PATH/TO/TRACKS/bin/rails r -e production 'MessageGateway.receive(STDIN.read)'</pre></li>
<li>Send an email to your newly configured address!</li>
</ul>
<p>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.
</p>
<p>
You may need to configure your <tt>site.yml</tt> to tell the message gateway to look at the <tt>to:</tt> field or <tt>from:</tt> field to
lookup Tracks' user from the email address in that field. </p>
<p>You can also send all email to a specific Tracks user. Configure mail_dispatch in site.yml to <tt>single_user</tt> and pass the login of the user:
<pre>TRACKS_MAIL_RECEIVER=<%=current_user.login%> /PATH/TO/TRACKS/bin/rails r -e production 'MessageGateway.receive(STDIN.read)'</pre>
</p>

View file

@ -1,119 +0,0 @@
<% has_contexts = !current_user.contexts.empty? -%>
<h1>Integrations</h1>
<p>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') %>.</p>
<br/><p>Contents:</p>
<ul>
<li><a href="#email-cron-section">Automatically Email Yourself Upcoming Actions</a></li>
<li><a href="#message_gateway">Integrate Tracks with an email server to be able to send an action through email to Tracks</a></li>
<li><a href="#mailgun">Send emails to Tracks with Mailgun</a>
<li><a href="#todo_rich_message_format">Rich Todo Message email format</a>
</ul><br/>
<p>Do you have one of your own to add?
<a href="http://www.getontracks.org/forums/viewforum/10/" title="Tracks | Tips and Tricks">Tell us about
it in our Tips and Tricks forum</a> and we may include it on this page in a future versions of Tracks.
</p>
<a name="email-cron-section"> </a>
<h2>Automatically Email Yourself Upcoming Actions</h2>
<p>If you enter the following entry to your crontab, you will receive email every day around 5 AM with a list of the upcoming actions which are due within the next 7 days.</p>
<textarea id="cron" name="cron">0 5 * * * /usr/bin/curl -0 "<%= root_url %>todos.txt?due=6&token=<%= current_user.token %>" | /usr/bin/mail -e -s 'Tracks actions due in the next 7 days' youremail@yourdomain.com</textarea>
<p>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?</p>
<a name="message_gateway"> </a>
<h2>Integrated email/SMS receiver</h2>
<p>
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:
</p>
<ul>
<li>Go to <%= link_to t('layouts.navigation.preferences'), preferences_url %> and
set your "<%= Preference.human_attribute_name('sms_email') %>" and
"<%= Preference.human_attribute_name('sms_context') %>" for todos sent in
via email (which could come from an SMS message)</li>
<li>In sendmail/qmail/postfix/whatever, set up an email address
alias to pipe messages to <pre>/PATH/TO/TRACKS/bin/rails r -e production 'MessageGateway.receive(STDIN.read)'</pre></li>
<li>Send an email to your newly configured address!</li>
</ul>
<p>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.
</p>
<p>
You may need to configure your <tt>site.yml</tt> to tell the message gateway to look at the <tt>to:</tt> field or <tt>from:</tt> field to
lookup Tracks' user from the email address in that field. </p>
<p>You can also send all email to a specific Tracks user. Configure mail_dispatch in site.yml to <tt>single_user</tt> and pass the login of the user:
<pre>TRACKS_MAIL_RECEIVER=<%=current_user.login%> /PATH/TO/TRACKS/bin/rails r -e production 'MessageGateway.receive(STDIN.read)'</pre>
</p>
<a name="mailgun"> </a>
<h2>Send emails to Tracks with Mailgun</h2>
<p>
If you want to email tasks to Tracks, but cannot run a mailserver on the same host,
you could use the <a href='www.mailgun.com'>Mailgun</a> support built in to Tracks.
</p>
<p>
For this to work your Tracks server will need to be reachable from the internet, so
that Mailgun can POST data to it.
<p>
<ul>
<li>Go to <%= link_to 'http://mailgun.com' %> and register for a free account.</li>
<li>Go to 'Routes' in the Mailgun control panel, and add a new route:</li>
<ul>
<li>'Filter expression' should be set to 'catch_all()'</li>
<li>'Action' should be 'forward("http://mytracksserver.domain.com/mailgun/mime")'
</ul>
<li>Go to <%= link_to t('layouts.navigation.preferences'), preferences_url %> and
enter your incoming Mailgun email address (e.g. tracks@user.mailgun.com) in the
"<%= Preference.human_attribute_name('sms_email') %>" box.</li>
<li>Select a default context for emails to be put in with
"<%= Preference.human_attribute_name('sms_context') %>"</li>
<li>Add your Mailgun API key (not the Public API key) to the Tracks 'site.yml'
<li>Update the mailmap in 'site.yml' to define which senders can send emails to
which incoming addresses. For example, to send emails from your work and home
email accounts to your tracks Mailgun route, set it up like this:
<pre class=code>
mailmap:
tracks@user.mailgun.org:
- me@myhome.domain.net
- mr.user@work.company.com
</pre>
</ul>
<p>All the comments about the email format from the section above apply to the
Mailgun handling, as the data is processed the same way</p>
<a name="todo_rich_message_format"> </a>
<h2>Rich Todo Message Format</h2>
<p> For both of the above methods, the follow format can be used:</p>
<pre>my awesome todo @context ~project &lt;131012 &gt;131009 #tag1 #tag2 *</pre>
<p>The fields are:</p>
<table>
<tr>
<th>Symbol</th><th>Meaning</th>
</tr>
<tr>
<td>@</td><td>The context to place the Todo in</td>
</tr>
<tr>
<td>~</td><td>The project to place the Todo in</td>
</tr>
<tr>
<td>&lt;</td><td>The due date for the Todo (may be 2 digits for day, 4 digits for month-day, or 6 digits for year-month-day)</td>
</tr>
<tr>
<td>&gt;</td><td>The due date for the Todo (may be 2 digits for day, 4 digits for month-day, or 6 digits for year-month-day)</td>
</tr>
<tr>
<td>#</td><td>A tag to apply to the Todo - may be used multiple times</td>
</tr>
<tr>
<td>*</td><td>Flag to star the Todo</td>
</tr>
</table>
<p>All symbols are optional, and text up to the first symbol (or end of string) is used as the description of the todo</p>

View file

@ -0,0 +1,85 @@
<% has_contexts = !current_user.contexts.empty? -%>
<h1><%= I18n.t 'integrations.title' %></h1>
<p><%= raw I18n.t 'integrations.intro', documentation_link: link_to(I18n.t('integrations.developer_documentation_link'), url_for(:action => 'rest_api')) %></p>
<br/><p><%= I18n.t 'integrations.contents_header' %></p>
<ul>
<li><a href="#email-cron-section"><%= I18n.t 'integrations.sections.automatic_email' %></a></li>
<li><a href="#message_gateway"><%= I18n.t 'integrations.sections.message_gateway' %></a></li>
<li><a href="#mailgun"><%= I18n.t 'integrations.sections.mailgun' %></a></li>
<li><a href="#todo_rich_message_format"><%= I18n.t 'integrations.sections.email_rich' %></a></li>
</ul>
<p><%= raw I18n.t 'integrations.add_your_own', tell_us_link: link_to(I18n.t('integrations.tell_us_link_text'), 'https://github.com/TracksApp/tracks/issues') %></p>
<a name="email-cron-section"> </a>
<h2><%= I18n.t 'integrations.sections.automatic_email' %></h2>
<p><%= I18n.t 'integrations.cron_1' %></p>
<textarea id="cron" name="cron">0 5 * * * /usr/bin/curl -0 "<%= root_url %>todos.txt?due=6&token=<%= current_user.token %>" | /usr/bin/mail -e -s 'Tracks actions due in the next 7 days' youremail@yourdomain.com</textarea>
<p><%= raw I18n.t 'integrations.cron_2', feeds_link: link_to(I18n.t('integrations.feeds_link_text'), feeds_path) %></p>
<a name="message_gateway"> </a>
<h2><%= I18n.t 'integrations.sections.message_gateway' %></h2>
<p><%= I18n.t 'integrations.message_gateway.description' %></p>
<ul>
<li><%= raw I18n.t 'integrations.message_gateway.instructions.1', preferences_link: link_to(t('layouts.navigation.preferences'), preferences_url), sms_email_name: Preference.human_attribute_name('sms_email'), sms_context_name: Preference.human_attribute_name('sms_context') %></li>
<li><%= raw I18n.t 'integrations.message_gateway.instructions.2', command: "<pre>/PATH/TO/TRACKS/bin/rails r -e production 'MessageGateway.receive(STDIN.read)'</pre>" %></li>
<li><%= I18n.t 'integrations.message_gateway.instructions.3' %></li>
</ul>
<p><%= I18n.t 'integrations.message_gateway.rich_api_tip' %></p>
<p><%= raw I18n.t 'integrations.message_gateway.configuration', site_yml: '<tt>site.yml</tt>', to_name: '<tt>to:</tt>', from_name: '<tt>from:</tt>' %></p>
<p><%= raw I18n.t 'integrations.message_gateway.one_user_configuration', single_user_var_name: '<tt>single_user</tt>', code: "<pre>TRACKS_MAIL_RECEIVER=" + current_user.login + " /PATH/TO/TRACKS/bin/rails r -e production 'MessageGateway.receive(STDIN.read)'</pre>" %></p>
<a name="mailgun"> </a>
<h2><%= I18n.t 'integrations.sections.mailgun' %></h2>
<p><%= raw I18n.t 'integrations.mailgun.description', mailgun_link: link_to('Mailgun', 'http://www.mailgun.com/') %></p>
<p><%= I18n.t 'integrations.mailgun.conditions' %></p>
<ul>
<li><%= raw I18n.t 'integrations.mailgun.instructions.1', mailgun_link: link_to('Mailgun', 'http://www.mailgun.com/') %></li>
<li><%= I18n.t 'integrations.mailgun.instructions.2' %></li>
<ul>
<li><%= I18n.t 'integrations.mailgun.instructions.2a' %></li>
<li><%= I18n.t 'integrations.mailgun.instructions.2b' %></li>
</ul>
<li><%= raw I18n.t 'integrations.mailgun.instructions.3', preferences_link: link_to(t('layouts.navigation.preferences'), preferences_url), sms_email_name: Preference.human_attribute_name('sms_email') %></li>
<li><%= I18n.t 'integrations.mailgun.instructions.4', sms_context_name: Preference.human_attribute_name('sms_context') %></li>
<li><%= I18n.t 'integrations.mailgun.instructions.5' %></li>
<li><%= I18n.t 'integrations.mailgun.instructions.6', code: '<pre class=code>
mailmap:
tracks@user.mailgun.org:
- me@myhome.domain.net
- mr.user@work.company.com
</pre>' %></li>
</ul>
<p><%= I18n.t 'integrations.mailgun.gateway_instructions' %></p>
<a name="todo_rich_message_format"> </a>
<h2><%= I18n.t 'integrations.sections.email_rich' %></h2>
<p><%= I18n.t 'integrations.email_rich.description' %></p>
<pre><%= I18n.t 'integrations.example_names.todo' %> @<%= I18n.t 'integrations.example_names.context' %> ~<%= I18n.t 'integrations.example_names.project' %> &lt;131012 &gt;131009 #<%= I18n.t 'integrations.example_names.tag.1' %> #<%= I18n.t 'integrations.example_names.tag.2' %> *</pre>
<p><%= I18n.t 'integrations.email_rich.fields_title' %></p>
<table>
<tr>
<th><%= I18n.t 'integrations.email_rich.symbol_title' %></th><th><%= I18n.t 'integrations.email_rich.meaning_title' %></th>
</tr>
<tr>
<td>@</td><td><%= I18n.t 'integrations.email_rich.field_descriptions.context' %></td>
</tr>
<tr>
<td>~</td><td><%= I18n.t 'integrations.email_rich.field_descriptions.project' %></td>
</tr>
<tr>
<td>&lt;</td><td><%= I18n.t 'integrations.email_rich.field_descriptions.due_date' %></td>
</tr>
<tr>
<td>&gt;</td><td><%= I18n.t 'integrations.email_rich.field_descriptions.due_date' %></td>
</tr>
<tr>
<td>#</td><td><%= I18n.t 'integrations.email_rich.field_descriptions.tag' %></td>
</tr>
<tr>
<td>*</td><td><%= I18n.t 'integrations.email_rich.field_descriptions.star' %></td>
</tr>
</table>
<p><%= I18n.t 'integrations.email_rich.fields_instruction' %>

View file

@ -1,52 +0,0 @@
<% has_contexts = !current_user.contexts.empty? -%>
<h1>Integratie</h1>
<p>Tracks kan met een aantal tools worden geïntegreerd...
Alles om je te helpen om dingen gedaan te krijgen!
Deze pagina heeft informatie over het tot stand brengen van sommige integratievormen.
Deze voorbeelden zijn niet altijd voor alle platformen van toepassing en
sommige voorbeelden vragen meer technische kennis dan anderen
Zie ook <%= link_to "de documentatie voor ontwikkelaars met Tracks' REST API", url_for(:action => 'rest_api') %>.</p>
<br/><p>Inhoud:</p>
<ul>
<li><a href="#email-cron-section">Email jezelf automatisch de acties met een aflopende deadline</a></li>
<li><a href="#message_gateway">Integreer Tracks met een email server om een actie via email naar Tracks te sturen</a></li>
</ul><br/>
<p>Heb je een tip om hier toe te voegen?
<a href="http://www.getontracks.org/forums/viewforum/10/" title="Tracks | Tips and Tricks">Vertel ons er over in onze
Tips and Tricks forum</a> en misschien voegen we jouw tip toe op deze pagina in een toekomstige versie van Tracks.
</p>
<a name="email-cron-section"> </a>
<h2>Email jezelf automatisch de acties met een aflopende deadline</h2>
<p>Als je de volgende regel toevoegd aan jouw crontab, dat ontvang je een e-mail op elke dag rond 05:00 met een lijst met acties waarvan de deadline afloopt binnen de komende 7 dagen.</p>
<textarea id="cron" name="cron">0 5 * * * /usr/bin/curl -0 "<%= root_url %>todos.txt?due=6&token=<%= current_user.token %>" | /usr/bin/mail -e -s 'Tracks actions due in the next 7 days' youremail@yourdomain.com</textarea>
<p>Uiteraard kan je ook een andere <%= link_to 'text feed gebruiken die Tracks biedt', feeds_path %> -- bijvoorbeeld een email met een lijst van acties voor een specifiek project naar een groep collega's die werken aan dat project?</p>
<a name="message_gateway"> </a>
<h2>Integreer Tracks met een email server om een actie via email naar Tracks te sturen</h2>
<p>
Als Tracks draait op dezelfde server als jouw mailserver, dan kan je de geïntegreerde mail handler gebruiken van Tracks. Om dit in te stellen:
</p>
<ul>
<li>Ga naar <%= link_to t('layouts.navigation.preferences'), preferences_url %>
en stel in "<%= Preference.human_attribute_name('sms_email') %>" en
"<%= Preference.human_attribute_name('sms_context') %>" voor acties die
verzonden zijn via email (die bijv. komen via een SMS message)</li>
<li>In sendmail/qmail/postfix/whatever, stel een email address
alias in om berichten door te sturen naar
<pre>/PATH/TO/TRACKS/bin/rails r -e production 'MessageGateway.receive(STDIN.read)'</pre></li>
<li>Verstuur een email naar het net geconfigureerde e-mail adres!</li>
</ul>
<p>Je kan ook de Rich Todo API gebruiken om acties te maken zoals "do laundry @ Home"
of "Call Bill > project X". Het onderwerp van het bericht zal de bijschrijving van de actie vullen,
de context, en het project, terwijl de body van het bericht de notities van de actie zal vullen.
</p>
<p>
Het kan nodig zijn om jouw <tt>site.yml</tt> te configureren om de message gateway te laten kijken naar het <tt>to:</tt> veld of het <tt>from:</tt> veld om
de Tracks-gebruiker op te zoeken met het emailadres uit dat veld. </p>
<p>Je kan ook alle email naar een specifieke Tracks gebruiker sturen. Stel mail_dispatch in site.yml in op <tt>single_user</tt> en geeft de login van de gebruiker door:
<pre>TRACKS_MAIL_RECEIVER=<%=current_user.login%> /PATH/TO/TRACKS/bin/rails r -e production 'MessageGateway.receive(STDIN.read)'</pre>
</p>