Skip to content
This repository has been archived by the owner on Nov 12, 2018. It is now read-only.

Commit

Permalink
Merge pull request #28 from geeeeeeeeek/release/1.0
Browse files Browse the repository at this point in the history
Release/1.0
  • Loading branch information
Zhongyi Tong authored and Zhongyi Tong committed Mar 1, 2016
2 parents c782206 + 3ff2e10 commit e26d837
Show file tree
Hide file tree
Showing 10 changed files with 146 additions and 44 deletions.
31 changes: 31 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
language: node_js
node_js:
- '5.2'
branches:
only:
- master
before_script:
- npm install
script:
- ./scripts/build-all.sh
- ./scripts/tar-all.sh
deploy:
provider: releases
api_key:
secure: ETudcaMBembv5mq5WcA0Zu5YCQt02A8sfMIYJ+XN0dTUCFRODYgyk8SiW3ndI4zLfhsc31KbYecSVfcrvYhPlkLucdhD0hY+v4mowrGaG6q3DUE4v9+qATOE5z51MPNTQO/suPNZpeFkSCKaWh6SY9oSd/tsD+YmbcpuD0//DMiFMpYqA8ueQ7yka4SmlZq8C48MsRbULAtyHNEVNJ4en9xdE9vFHZ45kM2A2IWYVikuCa5J6YoL7N2CyIFwtKMeF68d0vwidXUXEc7z1VOHwosG7V0vEfNRrIy4mft0tXyEYe/nM8GlYnirVRCy3xF4h4ssERXbLMuZSYGm+bg/pqReL+dvsN5oKszuo7IseZnE8QfmmhfbMB4dWf8Le5WXfFgJTG28lNvl2VwTTEW4Cj5qeJmfO524GydqRE+i3uQvW4c2tBTFmfpusPnaFqVXTPH7o54hT18hYvgaBvJQv6pyMNMLLXq0BbkzquTTWTwb8lSi8XiRr/fWkQreRZNofJc21ZUSI5YcuqZpzbz1fOLseC4QJ8YXQ9b2OU/LiFF3gvHTK6vSKMQmbOFg0zFXMi5FT1SzCi/mKduax/OR/H6lolVW83eXCG1Ni+sIrwUkp0d/UL6E1pVeJMibBrOEgriWIpD+AiVzNVyBdq/oDC6qG9IXRWzii9Ks6J9zH7k=
file:
- 'dist/mac-osx.tar.gz'
- 'dist/linux-x64.tar.gz'
- 'dist/linux-ia32.tar.gz'
skip_cleanup: true
on:
repo: geeeeeeeeek/electronic-wechat
branch: master
tags: true
notifications:
webhooks:
urls:
- https://webhooks.gitter.im/e/d6bab2376f47ee992d78
on_success: always # options: [always|never|change] default: always
on_failure: always # options: [always|never|change] default: always
on_start: always # options: [always|never|change] default: always
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
# CHANGELOG

**v1.0 (2016.03.01)**

1. 新增 阻止消息撤回的功能 (感谢 @arrowrowe 的贡献)
2. 新增 引入了 Travis CI 和 Gitter.im
3. 优化 贴纸显示的实现方式 (感谢 @arrowrowe 的贡献)
4. 优化 build 脚本 (感谢 @gaocegege, @viko16@htc550605125 的贡献)
5. 优化 Linux 下自动隐藏菜单 (感谢 @wenLiangcan 的贡献)
6. 优化 Linux 下用户头像的显示
7. 优化 禁用缩放、选中文本、默认光标

**v0.1 (2016.02.19)**

1. Create the project.
Expand Down
13 changes: 4 additions & 9 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,15 @@
# Contributing to Electronic WeChat

First of all, thanks for contributing to this project. It would be appreciated if you read though this contibuting guide.

## Issues

- Check if your issue is already [there](https://github.com/geeeeeeeeek/electronic-wechat).

- Check if your issue is `Electronic WeChat` related rather than upstream related. Here are some of the issues acknowledged by [`electron`](https://github.com/atom/electron/issues/).

- Cannot reload. Reloading was disable by me because of [electron issue #4324](https://github.com/atom/electron/issues/4324).

I will keep close attention to these issues and will update as soon as there is a fix.
- Check if your issue is `Electronic WeChat` related rather than upstream related.

- Follow the guide in the issue template.


## Pull Requests

The automatic workflow using CI has not been build up yet. If you insist to send a PR, which is absolutely welcomed, please make sure there is no hidden error as far as you can recognize.

**Remember**, the smaller your focus is on, the larger possibility the PR will get merged.
PR are always welcomed. It's better if you put up an issue before firing a PR. **Remember**, the smaller your focus is on, the larger possibility your PR will get merged.
8 changes: 1 addition & 7 deletions ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
First, make sure your issue is strictly related to the ***Electronic WeChat*** project. Some upstream issues caused by ***electron*** can be viewed in the **guidelines for contributing** showing above.

If it's a question or feature request, you can remove the template below.
First, make sure your issue is strictly related to the ***Electronic WeChat*** project. If it's a question or feature request, you can remove the template below.

#### Description



#### Steps to Reproduce Issue



#### Specifications

- Version of Electron (run `$ electron --version`): `v0.0.0`
Expand Down
46 changes: 22 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,35 @@
# Electronic WeChat

[![Gitter](https://badges.gitter.im/geeeeeeeeek/electronic-wechat.svg)](https://gitter.im/geeeeeeeeek/electronic-wechat?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=body_badge) [![Build Status](https://travis-ci.org/geeeeeeeeek/electronic-wechat.svg?branch=master)](https://travis-ci.org/geeeeeeeeek/electronic-wechat) [中文文档](README_zh.md)

**A better WeChat client on Mac OS X and Linux. Build with [Electron](https://github.com/atom/electron).**

*Electronic WeChat* is released by this open source project. While Web WeChat is a major component in the app, it should be noted that this is a community release and not an official WeChat release.

This app is still under development. Mainly tested on OS X, but should work on Linux.

![qq20160224-0 2x](https://cloud.githubusercontent.com/assets/7262715/13275230/96b81776-daed-11e5-98ce-3ee3bd82082e.png)

## Features

- Modern UI and full features from Web WeChat.
- Auto resize window.
**Electronic WeChat v.s. Mac WeChat**

- ​ Modern UI and full features from Web WeChat.


- Drag-to-send pictures.
- **Compatible with sticker messages.**
- Bug free.
- Prevent others from recalling messages.

**Electronic WeChat v.s. Web WeChat**

- **Compatible with sticker messages.** [[?]](https://github.com/geeeeeeeeek/electronic-wechat/issues/2)
- Independent app out of browser. Behaves like native.
- Open inhibited links without redirects (like taobao.com).

![qq20160224-0 2x](https://cloud.githubusercontent.com/assets/7262715/13275230/96b81776-daed-11e5-98ce-3ee3bd82082e.png)
**Electronic WeChat v.s. Linux WeChat**

- Well, you actually don't have a choice.​

## How To Use

Expand All @@ -29,33 +44,16 @@ cd electronic-wechat
npm install && npm start
```

You can also get a stable version via npm:

```shell
# via npm
npm i electronic-wechat
```

To pack into an app, simply type:
To pack into an app, simply type one of these:

``` shell
npm run build:osx
```

or

``` shell
npm run build:linux
```

or

``` shell
npm run build:win
```

#### Download App

If you only cares about the app, you can find it out in the [~~release (not available yet~~)](https://github.com/geeeeeeeeek/electronic-wechat/releases) section.
If you only cares about the app, you can find it out in the [release](https://github.com/geeeeeeeeek/electronic-wechat/releases) section.

#### License [MIT](LICENSE.md)
#### License [MIT](LICENSE.md)
58 changes: 58 additions & 0 deletions README_zh.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
# Electronic WeChat

[![Gitter](https://badges.gitter.im/geeeeeeeeek/electronic-wechat.svg)](https://gitter.im/geeeeeeeeek/electronic-wechat?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=body_badge) [![Build Status](https://travis-ci.org/geeeeeeeeek/electronic-wechat.svg?branch=master)](https://travis-ci.org/geeeeeeeeek/electronic-wechat) [English docs](README.md)

**Mac OS X 和 Linux下更好用的微信客户端. 使用[Electron](https://github.com/atom/electron)构建.**

*Electronic WeChat* 是本开源项目发布的产品。网页版微信是其中重要的一部分,但请注意这是一个社区发布的产品,而 *不是* 官方微信团队发布的产品。

这个应用仍在开发中。主要在 OS X 下测试,Linux 下亦可使用。

![qq20160224-0 2x](https://cloud.githubusercontent.com/assets/7262715/13275230/96b81776-daed-11e5-98ce-3ee3bd82082e.png)

## 应用特性

**Electronic WeChat v.s. Mac 官方微信客户端**

- 来自网页版微信的更现代的界面和更完备的功能
- 拖入图片、文件即可发送
- 阻止其他人撤回消息
- 没有原生客户端万年不修复的bug

**Electronic WeChat v.s. 网页版微信客户端**

- **能够显示贴纸消息** [[?]](https://github.com/geeeeeeeeek/electronic-wechat/issues/2)
- 原生应用的体验,独立于浏览器
- OS X中的dock未读消息计数和消息通知
- 直接打开微信重定向的链接 (如 taobao.com)

**Electronic WeChat v.s. Linux 官方微信客户端**

- 好吧,首先你需要有一个官方客户端

## 如何使用

在下载和运行这个项目之前,你需要在电脑上安装[Git](https://git-scm.com)[Node.js](https://nodejs.org/en/download/) (来自[npm](https://www.npmjs.com/))。在命令行中输入:

``` bash
# 下载仓库
git clone https://github.com/geeeeeeeeek/electronic-wechat.git
# 进入仓库
cd electronic-wechat
# 安装依赖, 运行应用
npm install && npm start
```

根据你的平台打包应用:

``` shell
npm run build:osx
npm run build:linux
npm run build:win
```

#### 直接下载应用

如果你希望开箱即用,你可以在[release](https://github.com/geeeeeeeeek/electronic-wechat/releases)中下载到最新的稳定版本。

#### 项目使用[MIT](LICENSE.md)许可。
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "electronic-wechat",
"version": "0.1.0",
"version": "1.0.0",
"description": "An Electron application for WeChat",
"main": "src/main.js",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion scripts/build-all.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ function build() {
build darwin x64
build linux ia32
build linux x64
build win32 ia32
#build win32 ia32
13 changes: 13 additions & 0 deletions scripts/tar-all.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/bin/bash

echo 'Start compressing for Mac OS X.'
tar zcf 'dist/mac-osx.tar.gz' 'dist/Electronic WeChat-darwin-x64'
echo 'Compressing for Mac OS X succeed.'

echo 'Start compressing for Linux x64.'
tar zcf 'dist/linux-x64.tar.gz' 'dist/Electronic WeChat-linux-x64'
echo 'Compressing for Linux x64 succeed.'

echo 'Start compressing for Linux ia32.'
tar zcf 'dist/linux-ia32.tar.gz' 'dist/Electronic WeChat-linux-ia32'
echo 'Compressing for Linux ia32 succeed.'
7 changes: 5 additions & 2 deletions src/inject-preload.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
"use strict";
const ipcRenderer = require('electron').ipcRenderer;
const webFrame = require('web-frame');
const menu = require('./menu.js');

const lock = (object, key, value) => Object.defineProperty(object, key, {
Expand All @@ -8,7 +9,9 @@ const lock = (object, key, value) => Object.defineProperty(object, key, {
}
});

lock(window, 'console', window.console);
webFrame.setZoomLevelLimits(1, 1);

//lock(window, 'console', window.console);

let angular = window.angular = {};
let angularBootstrapReal;
Expand All @@ -26,7 +29,7 @@ Object.defineProperty(angular, 'bootstrap', {
value.AddMsgList.forEach((msg) => {
switch (msg.MsgType) {
case constants.MSGTYPE_EMOTICON:
const rec = msg.Content.match(/^<msg><emoji.+cdnurl = "(.+?)".+thumburl = "(.+?)"/);
const rec = msg.Content.match(/<msg><emoji.+cdnurl = "(.+?)".+thumburl = "(.+?)"/);
if (rec !== null) {
let actualContent = msg.Content;
lock(msg, 'MMActualContent', actualContent);
Expand Down

0 comments on commit e26d837

Please sign in to comment.