Tag Archives: utility

Migrate live space to blogger (v1.1.1)

A new version of the live space export utility. The old version can not run because the live space has changed some codes in its web pages. Also some bugs have been fixed in this version.

Download link (v1.1.1):

http://cid-0ea641a5a7f665a1.skydrive.live.com/self.aspx/Public/livespaceexport.v1.1.1.zip

md5 sum: 1591c88501470b9292cff39a42eb209d

Please read the readme.txt file included in the zip package before use.

I ONLY MAKE A SIMPLE TEST. PLEASE LET ME KNOW IF THERE STILL IS ANY PROBLEM.

BE SURE SIGN IN YOUR LIVE SPACE WITH YOUR PASSWORD USING YOUR FAVORITE BROWSER BEFORE TRYING TO RETRIEVE LIVE SPACE POSTS.

The previous posts on this tool might be helpful if you are not clear how to set the parameters which are necessary to run the tool.

http://nanzhuotong.blogspot.com/2008/11/move-blog-posts-from-live-space-to.html (figures included to show the parameter configuration)

http://nanzhuotong.blogspot.com/2008/11/live-space.html (in Chinese, figures are also included)

一个获取并查看北京空气质量的工具,数据来自美国北京使馆Twitter

screenshot 
版本(b090627)的截图

功能

  • 从美使馆官方twitter(https://twitter.com/beijingair)上获取最新美国使馆发布的北京空气质量数据
  • 以时间序列图方式直观查看全部的历史数据
  • 提供逐小时和逐日两种方式
  • 数据可以导出至excel格式;图可以导出到常用的图像格式;支持将图和数据拷贝到剪贴板

使用说明,请查看包装包里的Readme.txt文件。

可运行版本下载地址:

http://cid-0ea641a5a7f665a1.skydrive.live.com/self.aspx/Public/bjair|_plot|_b090629.zip (最新版,现在客户端上无须要求安装 sql server compact ed.) 1.5MB

http://cid-0ea641a5a7f665a1.skydrive.live.com/self.aspx/Public/bjair%7C_plot%7C_b090628.zip (最新版,更新一点bug)

http://cid-0ea641a5a7f665a1.skydrive.live.com/self.aspx/Public/bjair%7C_plot%7C_b090627.zip

需要.net framework 3.5 sp1的支持,如果在你的windows机器上不能运行,请到http://www.microsoft.com/downloads/details.aspx?FamilyID=ab99342f-5d1a-413d-8319-81da479ab0d7 这里下载 .net framework 3.5 sp1并安装到你的机器上。

相关新闻:

美使館Twitter北京空氣質量受歡迎(BBC)

美使馆用Twitter发布北京空气质量监测(财经网)

烟雾笼罩北京 空气质量再成焦点(网易)

美国使馆的北京空气质量

我从BeijingAir twitter网站(https://twitter.com/beijingair)上下载了全部的北京空气质量数据。这些数据是美国驻北京使馆测的,并在他们的twitter网站上实时更新。他们声明说数据只反映使馆所在地小范围的空气质量,而不代表整个北京的情况,他们是目的是为了给使馆工作人员提供有关空气质量的信息。而北京官方发表的空气质量要好于此数据。

空气质量定义见http://www.airnow.gov/index.cfm?action=static.aqguidepart。分,

好 0-50
中等 51-100
对易感人群不好 101-150
不利于健康 151-200
非常不利于健康 201-300
灾难 >300

以下各图横轴是时间,纵轴是北京美国使馆观测点的空气质量指数(其实监测的只有直径2.5微米的悬浮颗粒,此标准与国内监测10微米不一致,所以不能简单地对比这些图与北京的官方通报)。

image
6月份以来的北京逐小时空气质量指标。绿线以上代表了非常不利于健康和灾难性污染。

image
6月份以来的北京逐日平均空气质量指标。

image
08年10月份以来的北京逐小时空气质量指标。达500的重度污染发生次数不少。

image 
08年10月份以来的北京逐日平均空气质量指标。

粗粗一看,好像不是很乐观。至少说明在该监测点情况不是很好。北京的环保还任务艰巨。懒得做进一步的统计分析(比如200以上的天天数比例等)。有些东西还是糊涂些好,不必搞这么清楚。

对本程序感兴趣的,可以与我联系(giscn#msn.com)索取可执行文件和源代码。空气质量数据是直接从twitter网站读取并存在本地数据库。从技术上讲,里面有一些比较感兴趣的东西,以后我会逐渐整理成文档发出来。

开心网争车位自动工具 v1.0.2

一些bug的修正。下面是Readme的内容。

开心网(kaixin001.com)争车位自动停泊车工具
Zhuotong Nan (zhn1@pitt.edu)

最新更新 2009年1月3日(美国东部时间)

如何运行
开始菜单,运行,键入cmd打开命令窗口,cd进入到此工具所在的目录,键入kaixinCarWar运行。
也可以直接在资源浏览器里双击运行。
第一次运行时,会要求输入登录开心网的用户名和密码。
目前没有图形界面。

如何退出

在命令窗口里键入q退出此程序。

配置

使用任何文本编辑器,打开.config文件,进行参数的配置。只有当你明确每个参数是什么意思时,才可以修改。否则请联系作者。
用户名和密码信息存储在另外的配置文件里。
在xp下,是在C:Documents and Settings<USER>Local SettingsApplication DataZhuotong_NanKaixinCarWar.exe_<…>这个目录下。
进入此目录,删除全部文件,再运行KaixinCarWar.exe,会重新提示输入用户名和密码。
在vista下,位置是在C:Users<USER>AppDataLocalZhuotong_NanKaixinCarWar.exe_<…>这个目录下。

平台支持

支持.net 2.0的任何平台(安装了.net 2.0的xp,vista等)

版本历史

ver. 1.0.2 (3/1/2009)
* 修正了车名中带空格的车辆无法取回的问题
* 翻译了README的一些中文说明

ver. 1.0.1 (12/3/2008)
* make it work with the friendlist pattern that has changed recently.

ver. 1.0 (10/28/2008)
+ optimized parking algorithm
+ whitelist support
+ neighbor support
+ add a console passworld input class which will be enabled at the first time you run it.
+ simple exception handling
* fix possible WebException due to network timeout
* bugs fixed
+ now support automatically parking

ver. 0.2 (10/23/2008)
* change the cash pattern to make it capture correctly.

ver. 0.1 (10/21/2008)
+ Initial release
+ Monitor the parking lot and automatically claim their profits by setting a claim level.
+ Use a configuration file to set up the program.

图例
lengend
+ add
– remove
# enhance
* fix

http://cid-0ea641a5a7f665a1.skydrive.live.com/embedrow.aspx/Public/KaixinCarWar.exe.v1.02.zip

P.s,

如果运行提示,应用程序正常初始化失败,说明没安装.net 2.0
安装.net framework 2.0运行包,点这里下载.net 3.5 sp1即可。Vista本身已经安装。

Live Space空间博客导出工具

Live Space博客导出工具
Ver.1.1
Zhuotong Nan (zhn1@pitt.edu)

什么用

本工具将Windows Live Space的所有帖子导出成一个XML文件,利用Google Blogger的Import功能,可以将这些帖子导入到Blogger。
本工具通过使用页面分析的方法避免了传统使用Weblog API有帖子个数的限制(space读取20个帖子,Blogger分布每天50个帖的限制)。

如果您是资深的live space用户,已经在space上有很多的帖子,这时如果因为各种原因(比如因为国内封禁了您的space)想转移到
Blogger,本工具可以极大的方面您。此外,Blogger的确有比space更为强大的功能。

生成XML后再作什么

登录到你的Blogger,访问 http://draft.blogger.com/home, 然后点击 Settings,可以看到 Import blog, Export blog和 Delete blog
等。使用Import blog功能将生成的XML文件导入到Blogger。发布后的Blogger被标记为imported,在后台发布这些imported帖子,
或者删除这些导入帖子。

运行需求

.net framework 2.0 或以上。可以从微软站点获取。
这是framework 3.5的链接,
http://www.microsoft.com/downloads/details.aspx?familyid=AB99342F-5D1A-413D-8319-81DA479AB0D7&displaylang=en

更多帮助

有关界面各参数的设置,请访问 http://nanzhuotong.blogspot.com
在此站点还可以获取帮助或者提交bug报告。
最新版也将在此站点发布。

image 
第一次运行,填写各必要的参数

image
正在运行

image
关于

Ver. 1.1
+ add a simple Chinese readme file.
* fix bug that program run even when no necessary info is provided. (11/12/08)
+ include Microsoft.WindowsLive.Id.Client.dll in the distr pack. (11/8/08)
# passwords now are saved to config file with md5 encrypted.
# add a much nice about box
+ localized, Simplified Chinese supported. (11/7/08)

Ver. 1.0
+ initial release (11/7/08)

http://cid-0ea641a5a7f665a1.skydrive.live.com/embedrowdetail.aspx/Public/livespaceexport.v1.1.zip
MD5: da31bf89753721f47bd8d3d33aabd228

Move blog posts from Live Space to Google Blogger

I developed a small tool to enable the massive posts movement to the Google Blogger. I attached the README.txt file below.

http://cid-0ea641a5a7f665a1.skydrive.live.com/embedrowdetail.aspx/Public/livespaceexport.v1.zip
md5 digest: 401b130f69a0d83f3696c6c07a6d0c0b

Live space export utility
Ver.1.0
Zhuotong Nan (zhn1@pitt.edu)

PURPOSE

This tool is to export all live space posts (without 20 posts limit due to using a different method to achieve posts) and
to generate a xml file in a format which can be imported to Blogger.

This tool is specially useful when you want to move to a newly established Blogger. Considering you have already written
hundreds of posts in your live space, it is impossible to move all posts manually. The existing tools on the Internet
with similar purpose have more constraints, for ex, 20 posts max from live space, and 50 posts per day on the Blogger side.

The tool is designed to address those issues.

CONFIGURATION

Windows Live ID – your live id. Mine is giscn@msn.com.

Live space user name – my space is http://nzt.spaces.live.com, in this case the user name is nzt.

Live space secret word – go to your live space setting, enable your email publishing. the secret word can be found there.

Start page to navigate all posts – sign in your space, it is the link address leading to the Summary list of Blog,
My start page is like http://nzt.spaces.live.com/?_c11_BlogPart_BlogPart=summary&_c=BlogPart, replace nzt with
your name. This tool will use the link to achieve all posts list.

Use local buffer posts listing file – the first time it always gray out. After you downloaded the Live space posts list (posts
contents have not yet downloaded at that time), the posts list were saved to a local file named blogposts.txt in the current
directory. Then by enabling this option, the tool will skip the step of downloading posts list, and then continue to catch
posts contents as well as to form a final xml file.

BlogID – your Blogger id. when you log in your Blogger space, click the Customize link, you will see
a url in your browser addr bar like http://www.blogger.com/rearrange?blogID=207104551370538866, the number string here is
your id (here actually it is mine, ^_^).

Blogger user name – generally your gmail account
Blogger password – gmail password

Xml file name – the posts from live space will be organized in this file. Import this file to Blogger using Import from
Blogger in draft. To get the import function, at the time of this release, log in your blogger, and go to visit
http://draft.blogger.com/home, then click Settings on that page, you can see Import blog, Export blog and Delete blog.

WHAT TO DO NEXT

log in your blogger, and go to visit http://draft.blogger.com/home, then click Settings on that page, you can see
Import blog, Export blog and Delete blog. Use Import blog to import the created xml file. Do not worry about existing
blogger posts, they will be kept. the imported posts will be assigned with imported tag, you can make decision to publish
or delete some or all of them.

HOW IT WORKS

get posts list from live space -> download all posts -> get existing posts of your Blogger -> append posts from live space
to your existing Blogger posts to generate a xml file for import -> import to Blogger (thanks to draft Blogger)

I did not implement the import functionality in this tool based on the network consideration. The created xml file might be large
in size. In this case it requires much time to import even in a very good network condition. You decide when you do the import
using the xml file.

IMPORTANT

The tool will not alter/delete/add any post to your live space. Existing blogger posts will be exported and posts from live space
will appended to existing blogger posts. the time stamps of live space posts will be kept.

If you only import partial posts of live space to your Blogger, for ex due to network problem, make sure you delete those before
you do the second import. otherwise there will be duplicated posts.

The tool only communicates to your live space and your blogger.
For the sake of safety, please compare md5 of the zip package downloaded with the md5 string on author’s Blogger.

REQUIREMENTS

.net framework 2.0 or above is required to run it. get it from ms website.
here is the link for the framework 3.5,
http://www.microsoft.com/downloads/details.aspx?familyid=AB99342F-5D1A-413D-8319-81DA479AB0D7&displaylang=en

HELP

Visit http://nanzhuotong.blogspot.com for help and bug report.
Latest available version will also be published in that web site.

Ver. 1.0
+ initial release (11/7/08)

p.s. forgive my English and typos, I am not native English speaker.

 

image
the first time the tool run

image
properly configure it

image
the start page of summary list of posts. the page url is necessary to make the tool work.

image
enable the email publishing and set the secret word. secret word acts as password to access the live space api.

image
click start! to run it

image
you can cancel the running at any time. note in this case the formatted xml file is not completed.

image
after you downloaded all the posts, from the draft Blogger to reach Setting link (different from the normal Blogger setting link)

image
following the setting link from draft Blogger, see the Import blog function. follow its steps, good luck.

HtmlDecode Tool

It’s a very simple tool doing the html decoding. I developed it today because when I searched the Internet, I cannot locate such a tool from so many search results. There is some web site with similar conversion function. But I hate the ads on the website, which makes my laptop work slowly.

image

Look at the figure above. Put the texts to be decoded into the upper textbox, and press “Covert & copy” to do the decoding. The decoded strings will be shown on the lower textbox and copied to the clipboard when press that button. Then you can easily paste to anywhere else without doing selection and ctrl+c.

http://cid-0ea641a5a7f665a1.skydrive.live.com/embedrow.aspx/Public/HtmlDecoded.zip

To run it, you need install .net 2.0 runtime. Source codes are also included. VC# 2008 express edition is used.