arvida/runkeeper-activities

语言: Ruby

git: https://github.com/arvida/runkeeper-activities

RunKeeper活动的非官方ruby客户端
Unofficial ruby client for RunKeeper activities
README.md (中文)

= RunKeeperActivities gem

runkeeper-activities gem是{RunKeeper} [http://runkeeper.com]活动源的非官方客户端, 它没有得到FitnessKeeper Inc.的认可或附属。它基本上对RunKeeper的一些掠夺 公共配置文件页面和js支持文件。

==背景

我一直在使用RunKeeper跟踪我的运行大约两年,并且非常喜欢这项服务。不过那里 对于您的数据来说还没有正式的API或RSS-feed,从他们的支持论坛来看,它看起来是未来的计划。 我开始觉得能够通过Ruby访问我最近在RunKeeper上的活动的冲动,所以我做了这个宝石。

6月7日更新 - {A“graph”API即将推出} [http://developer.runkeeper.com]

==安装

如果您使用Bundler将gem添加到您的Gemfile中     宝石'跑步者 - 活动' 做一个     捆绑安装

不使用捆绑器?做一个     gem安装runkeeper-activities 并要求宝石     需要'runkeeper-activities'

==示例

require 'runkeeper-activities'
user = RunKeeperActivities::User.find_by_username(YOUR_RUNKEEPER_USERNAME)
activity = user.activities.first
puts "On #{activity.start_time} #{user.name} completed a #{activity.distance} #{user.distance_unit} #{activity.type.downcase} activity"

===可用数据

在+用户+实例上,您可以访问+用户名+,+名称+,+ profile_url +,+ profile_image_url +,+ distance_unit +,+ duration_unit +, + pace_unit +,+ speed_unit +,+ calories_unit +,+ elevation_unit +和+ activities +。 在+ Activity +实例上你可以访问+ start_time +,+ end_time +,+ distance +,+ duration +,+ pace +,+ speed +,+ calories +,+ elevation + +消息+和+ summery +。

RunKeeper上有很多可用的数据,应该很容易添加支持。

==贡献

找到了一些不起作用或想要添加功能的东西?添加{issue} [https://github.com/arvida/runkeeper-activities/issues]或做一个{fork} [http://help.github.com/fork-a-repo/]并发送一个拉请求。

本文使用googletrans自动翻译,仅供参考, 原文来自github.com

en_README.md

= RunKeeperActivities gem

The runkeeper-activities gem is a unoffical client for the {RunKeeper}[http://runkeeper.com] activity feed,
it is not endorsed by or affiliated with FitnessKeeper Inc. It basically do a bit of scraping of RunKeeper's
public profile pages and js-support files.

== Background

I have been using RunKeeper to track my running for about two years and really like the service. However there
is no official API or RSS-feed for your data yet, from their support forum it looks like it's planned for the future.
I started to feel the urge to be able to access my recent activites on RunKeeper via Ruby so I made this gem.

Update 7 June - {A ”graph” API is on the way}[http://developer.runkeeper.com]

== Installation

If your using Bundler add the gem to your Gemfile
gem 'runkeeper-activities'
and do a
bundle install

Not using bundler? Just do a
gem install runkeeper-activities
and require the gem with
require 'runkeeper-activities'

== Example

require 'runkeeper-activities'
user = RunKeeperActivities::User.find_by_username(YOUR_RUNKEEPER_USERNAME)
activity = user.activities.first
puts "On #{activity.start_time} #{user.name} completed a #{activity.distance} #{user.distance_unit} #{activity.type.downcase} activity"

=== Available data

On a +User+ instance you have access to +username+, +name+, +profile_url+, +profile_image_url+, +distance_unit+, +duration_unit+,
+pace_unit+, +speed_unit+, +calories_unit+, +elevation_unit+ and +activities+.
On a +Activity+ instance you can access +start_time+, +end_time+, +distance+, +duration+, +pace+, +speed+, +calories+, +elevation+
+message+ and +summery+.

There is a bunch of more data available on RunKeeper that should be pretty easy to add support for.

== Contribute

Found something that doens't work or want to add a feature? Add an {issue}[https://github.com/arvida/runkeeper-activities/issues] or do a {fork}[http://help.github.com/fork-a-repo/] and send a pull request.