2014.7.23 summary

实习到现在,每天基本都在忙碌中度过,唯独这两天,每天准时六点从公司撤退,然后去西郊利物浦打个球,打到差不多8点,再去吃个晚饭,回来舒舒服服洗个澡。

今天把sign的事情过程是理清楚了,明天做一下测试。然后ut也搞定了。

明天就把sign搞定,就开始研究下一步的工作了。

突然意识到时间过得好快啊,再过半个月就要发工资了。。。。。。。。。。。。。

发表在 Internship in Microsoft | 标签为 , | 留下评论

2014.7.22 summary

今天Leo来上班了。我上午研究了一下codecoverage。。一点头绪都没有,感觉配置好麻烦好麻烦好麻烦。
中午和Leo聊了一下intern期间的一个走向,又加了两个任务,一个是multi-project的一个支持,还有一个是BVT,不过后者不是必须的。

下午参加了一个brain storm,关于FTE的haskson,也叫oneweek challenge,差不多是提出一些创意,然后做一些demo和presentation,这个过程只有3天,更多的是看创意和可行性,不需要完全体。。prize有$10,000。。。
但是我是intern,又是vender,也就看看,看看组里面到时候能不能获奖,获奖了估计就可以吃饭了~

后来下午做了一下UT的脚本,和UT的分析,差不多能搞定的时候Leo又让我做一个sign,这个工作priority比较高,所以要提前,估计明天就得搞定。

明天就把sign搞定,然后把ut弄好吧,这估计就是这周的任务了。。。

准备早点下班回家,去打一次球,感受一下氛围,顺便减减肥,晚上还有一个小meeting。。

发表在 Internship in Microsoft | 标签为 , | 留下评论

2014.7.21 summary

今天早上乘7点的车从家里过来,还算顺利,9点多也是到公司了。。组里面第三个到的。

今天首先找出了上个星期遗留的神奇的build的问题,是因为64位版本的build依赖于32位,而其中的操作可能是剪切,而非copy,所以导致文件的丢失。

然后fix好这个bug,果然今天youhua那里就有专门的人开始测系统了。。。。

本来准备下一个阶段的,但Leo今天生病没来,我就后来自己看了看codecoverage工具。

感觉有点虚,想早点回家睡觉。。。。。。

发表在 Internship in Microsoft | 标签为 , | 留下评论

2014.7.18 summary, weekly report

Ash.. Feel stressed and unhappy.
Blow is my email to everyone in the team. It seems that James not knowing what I am doing and he might think my process is slow. damn it….

Hi all:
During the past week. What I have done are as follows.
1. I wrote an auto check history program, which could check if there is any check-in, modify or other changes to the Device Health. And then generate a report to every member of the team.
2. I also developed an auto-build program, which could build the whole system and record the errors and warnings during the build process. The process are as below:
a) Build the whole system in 16 different versions.
b) Analysis the errors and warnings during the build process.
c) Package the errors and warnings as an email and then send to every member of the Device Health.
d) Copy the already built project to \\stcsrv-g39\DeviceHealth_V2

Note: the build system is auto-run every 6 hours.

Plan for next week:
1. Auto run unit test, analysis the result and send to every member of the team.
2. Caculate the code coverage and make a report.

——————————————
Shuaiqi Xia (Tony)
STCA IEC
TEL: +86 15805197235

Here is another mail I send to the Device Health Team…

Hi all:
Due to mine unfamiliar with developing such a kind of build system, I feel sorry for the slow process. But, some functions could be used currently.
First of all, every 6 hours the system will auto check the changes of Device Health, to see if there is any check-in, delete, modify. And then send an email to all of you.
Besides, the Device Health will auto build every 6 hours to 16 different versions. And the errors and warnings during the build process will be sent to you after my analysis, where some unmeaningful warnings will be filtered.
Everyone could check the Device Health in \\stcsrv-g39\DeviceHealth_V2

My plan for next week is to develop the auto-UT and to get the code coverage. I will try my best to do my work quickly and efficiently.
If you have any questions or suggestions or other requirements, please contact me.

Best regards,

——————————————
Shuaiqi Xia (Tony)
STCA IEC
TEL: +86 15805197235

发表在 Internship in Microsoft | 标签为 , , | 一条评论

2014.7.17 summary

今天,build的脚本已经搞定了,已经能自动build了,并且不同版本都能控制了。
就是每次build时间比较久,可能全部弄好要15min。。。。每次有没有问题都要等,有点蛋疼。。。

明天要上C#了,并且发邮件了,还有分析build的结果。做完就可以回家了。。

额,今天听Leo讲了讲自己的“身世”,待过PPLIVE,创业过被360收购,后来也有参与创业失败,然后才来微软。。挺丰富的经历,以后多学习学习,多聊聊~~

That’s it。

发表在 Internship in Microsoft | 标签为 , | 留下评论

2014.7.16 summary

今天,已经能自动检测是否有更新,然后将最近6个小时内的更新发送邮件了~,我只能说,还可以。

明天就要进行build的操作了,本以为挺简单的。但是当知道build一下整个系统要半个小时。。感觉有点蛋疼。还要记录各种错误日志,然后分析。。
想想就有点烦人。。

行吧,明天好好做呗,做不好都不能安心回家。。。坑。

哦。

发表在 Internship in Microsoft | 标签为 , , | 留下评论

C#执行.bat脚本文件

本来准备用封装好的可以执行cmd命令的方法执行.bat的,但是总是有问题,后来找了点资料,自己写了一个方法执行.bat

1
2
3
4
5
6
7
8
9
10
11
public static void RunBat(String batAddress)
{
Process process = new Process();
process.StartInfo.FileName = "cmd.exe";
process.StartInfo.FileName = batAddress;
process.StartInfo.UseShellExecute = true;
process.StartInfo.CreateNoWindow = false;
process.Start();
 
process.WaitForExit();
}

关键在于把UseShellExecute设置成true。

发表在 C# | 标签为 , | 留下评论

2014.7.15 summary

昨天睡得好少,不过今天白天还是挺有精神的。感觉来MS之后,再也没有午睡的习惯了。周围人都挺拼的。。

今天在C#上实现了history和get功能,已经把异常机制加了进去,但是最后应该还会修改,加进去警报机制,比方说有问题要send email出来。
反正有些bug de了好久好久。。最好突然想到,很多操作其实可以放在脚本里,直接批量执行。
等等会贴一个c#调用bat的方法。

刚刚Leo又给我分配了远程机子。24G的内存,现在自己的机子是16G,加起来就是40G了,硬盘加起来应该5个T多了。。第一次操作这么厉害的电脑。不过要是有两个显示屏就更好了,因为两个桌面切换起来还是很麻烦,等等问问Leo。。。估计他也搞不定。

等等准备把远程服务器上的环境配置好,跑一遍现有的代码,然后就收拾回家,回家睡觉。

明天研究一下email功能,还有就是试图build一下。

PS:感觉昨天说的话抵得上好久好久说的话。

发表在 Internship in Microsoft | 标签为 , , | 留下评论

2014.7.14 summary

今天,是第二周了。
做了挺多事情,首先把bat脚本基本整合出来了,今天添加了get功能,就是sink。然后开始了C#的开发之路。
到目前为止,成功的将整个顺序流程(没有出错流程)的check history,get结束了。
里面有一个调用命令行的方法真是让我头疼到爆。。
在Leo和我自己的努力下,终于解决。

明天不多说,优化这个大流程,同时加入check out步骤,并且开始研究unit test如何在这个过程中使用。

PS:今天下午Leo说晚上之前应该要完成的任务的时候,心里有点虚,真心有种赶ddl的感觉,感觉压力还是蛮大的,至少周围人一直在工作,不怎么休息,也许也是热爱吧。。。。。。。。

发表在 Internship in Microsoft | 标签为 , , , | 留下评论

C#调用cmd命令行,执行一个脚本后,并传入命令

今天因为项目需要,要调用winodws命令行。本来有现成的代码可以复用,但是我自己的需求又不大一样。
一开始一直不能run的原因是创建process然后传入cmd命令时,没有以”/c”或者”/k”开头,所以传进去的命令根本不能解读。这个bug还是Leo帮忙de的。。

然后就是我自己一个人的问题了,我因为环境需要,cmd起来后要先执行一个tfs脚本,使tfs命令能够在命令行使用。但是我又要之后传入tf的操作命令,这两个有先后关系,而process每次只能传入一条命令,再传另一条就需要新建process了。。
所以我一直不能做到同时把这两个传进去。
最后,通过网上的启发,以及自己的尝试,发现process的startInfo可以自己配置一个argument,这个argument可以配置成脚本路径,整个思路有点像一个环境变量的配置。
话不多说,贴入代码:

1
2
3
4
5
6
7
8
9
10
Process process = new Process();
process.StartInfo.FileName = "cmd.exe";
process.StartInfo.Arguments = "/k \"D:\\softwares\\Microsoft Visual Studio 12.0\\VC\\vcvarsall.bat\" x86";
process.StartInfo.UseShellExecute = false;
process.StartInfo.RedirectStandardInput = true;
process.StartInfo.RedirectStandardOutput = true;
process.StartInfo.CreateNoWindow = false;
process.Start();
process.StandardInput.WriteLine(cmdLine + " > " + logFileName);
process.StandardInput.Close();

每次都是这种纠结的小错误最折磨人了。。。

发表在 C# | 标签为 | 留下评论