diff --git a/README.md b/README.md index 2f25509..9902646 100644 --- a/README.md +++ b/README.md @@ -9,11 +9,11 @@ Python版本 ![screenshot](https://raw.githubusercontent.com/taizilongxu/douban.fm/master/img/2.png) -###为什么Python版本 +###Do something cool! 其实Node.js版本已经很好了,功能齐全,但是我发现在我的zsh + tmux环境下颜色竟然显示不出来,感觉很蛋疼. -###安装 +###Setup sudo pip install douban.fm @@ -21,15 +21,15 @@ Python版本 sudo apt-get install mplayer -###使用 +###Usage 在终端下直接输入douban.fm -###登陆 +###Login 第一次登陆需要输入账号,密码,程序不会保留密码,而是保存返回的token存储在.douban_token.txt,下次登陆无需输入密码. -###按键 +###Keys 支持vim按键 @@ -44,7 +44,7 @@ Python版本 * b 不再播放 * q 退出 -###已完成功能 +###Done * 登陆token * 显示PRO diff --git a/douban/cli.py b/douban/cli.py index 16d153b..47ec873 100644 --- a/douban/cli.py +++ b/douban/cli.py @@ -18,7 +18,7 @@ class Cli(object): def __init__(self, lines): self.love = colored('♥ ', 'red') self.lines = lines - self.markline = 2 # 箭头行 初始化设置默认频道 + self.markline = 0 # 箭头行 初始化设置默认频道 self.topline = 0 # lines self.displayline = self.markline # 初始化歌曲信息显示行 self.screenline = self.linesnum() - 4 # 屏幕显示行数 diff --git a/douban/douban_token.py b/douban/douban_token.py index a189e8c..39a03c0 100644 --- a/douban/douban_token.py +++ b/douban/douban_token.py @@ -48,7 +48,7 @@ def login(self): "登陆douban.fm获取token" if os.path.exists('.douban_token.txt'): # 已登陆 - with open('.douban_token.txt', 'r') as f: + with open(os.path.expanduser('~') + '/.douban_token.txt', 'r') as f: self.login_data = pickle.load(f) self.token = self.login_data['token'] self.user_name = self.login_data['user_name'] diff --git a/setup.py b/setup.py index c6e13f7..ce5cb6c 100644 --- a/setup.py +++ b/setup.py @@ -5,14 +5,12 @@ 打包的用的setup必须引入, """ -VERSION = '0.2.1' -with open('README.md') as f: - long_description = f.read() +VERSION = '0.2.5' setup(name='douban.fm', version=VERSION, description="a tiny and smart cli player of douban.fm based on Python", - long_description=long_description, + long_description='just do something cool!', classifiers=[], # Get strings from http://pypi.python.org/pypi?%3Aaction=list_classifiers keywords='python douban douban.fm terminal', author='taizilongxu', @@ -24,7 +22,6 @@ zip_safe=True, install_requires=[ 'termcolor', - 'requests', ], entry_points={ 'console_scripts':[