srb提供的python库

srb-lib-004的Python项目详细描述


#srblib

[![欢迎投稿](https://img.shields.io/badge/contributions-welcome-brightgreen.svg?style=flat)(https://github.ocm/srbcheema1/srblib/issues)
[![一个srbcheema1产品](https://img.shields.io/badge/-a%20srbcheema1%20production blue.svg)(https://github.com/srbcheema1)
[![开源爱情](https://badges.frapsoft.com/os/v1/open-source.png?(https://github.com/srbcheema1/srblib)
[![HitCount](http://hits.dwyl.io/srbcheema1/srblib.svg)(http://hits.dwyl.io/srbcheema1/srblib)


****srblib**是一个数字的Python库,用来存放我有用的、可以在其他项目中使用的python脚本。





















-使用pip安装,user`--user` flag
```
python3-m pip install--user srblib
````

\r/>\r从源代码构建

-clone存储库并签出以稳定提交
````
git clone https://github.com/srbcheema1/srblib
cd srblib
git checkout<;最新版本为:v0.0.x>;
```


-安装要求
````
python3-m pip-pip-install--user-r-requirements.txt
````
>-安装srblib
````````
``````````
>`````````
``````
>``````
>``````
>
`````````>
>>
``````````````````````````
`````````;提供的课程



-颜色-带有颜色名称和一种静态打印功能,它将彩色输出打印到strderr
```
colour.print(message,colour.red)前台打印为红色
colour.print(message,colour.fullgreen)后台打印为绿色
colour.print(message,colour.fullgreen+colour.red)表示背景为全绿,前景为红色
````
-srbbank-一个类,用于存储程序稍后使用的内容。可以充当数据库
```````
a=srbbbank('db'u name''db'u name'''''''''''''''db'u name就是你的数据库名
a['hello']=“world”
b=srbbbank('db2','password'''''br/>b['hello']=“peeps”
退出代码并启动新会话
a=srbbbank('db'u name'''''''''''''''''''''''a['hello''''''''''''''''''''''''''''''''''','密码')
print(b['hello'])'peepps'
``````
-srbjson-一个更容易使用json文件的类
````
a=srbjson('json/path')
a['hello']='world'
;'退出代码,开始新的会话
a=srbjsson('json/path''json/path')
prinprint(a['hello'])
'world'
``````````
```````````````>-br/>-srbjson-一一个使用表格数据的类读写json,xlsx,csv文件
````
a=tabular('path/to/file')可以接受扩展名为csv,json,xlsx
print(a)以表格的形式打印表格
data=a.matrix;以列表的形式获取数据,即matrix
json_data=a.json;以字典列表的形式获取数据,即json
print(a[1]['name'])这里name是用于命名列的属性
print(a[0])prints attributes
print(a[1])。#打印第一行(基于0)
print(a['name'])打印具有属性'name'的列
a.write_xls('output/path')
a.write_csv('output/path')
a.write_json('output/path')
````

可在Windows和Linux上运行。
-get_os_name-返回操作系统名称。值为windows、linux或mac
-已安装-检查以下应用程序是否安装在计算机上
-文件扩展名-从文件路径返回文件的扩展名,如果没有扩展名,则可能返回“”-文件名-从文件路径返回文件名
-删除-递归删除路径。它删除该路径下的所有文件和文件夹
-ValIFyx文件-验证文件是否存在。如果不是,它将创造一个。如果需要的话,也创建父类
-ValIFyx文件夹-验证文件夹是否存在。如果不存在,则创建一个。如果需要,还可以创建父级


\图/srblib/debug.json



\[github](https://raw.githubusercontent.com/srbcheema1/cheemafy/master/myplugins/extra-things/png-images/social/github.png)(https://github.com/srbcheema1/)
[![LinkedIn](https://raw.githubusercontent.com/srbcheema1/cheemafy/master/myplugins/extra-things/png-images/social/linkedin-48x48.png)(https://www.linkedin.com/in/srbcheema1/)
[![脸谱](https://raw.githubusercontent.com/srbcheema1/cheemafy/master/myplugins/extra-things/png-images/social/fb.png)(https://www.facebook.com/srb cheema/)




欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
persistence Berkeley DB(Java版)在应用程序运行之间不是持久的   java使调度方法线程安全   java有更好的(java8?)收集异常的“原因堆栈”的方法?   java帮助我找到错误:方法声明无效;需要返回类型   java如何自动删除子实体?   sql Hibernate使用Java List实现多对多双向映射   java创建一组需要帮助的对象   目标c将Java程序绑定到Cocoa接口   多线程Java:同步操作与波动性到底有什么关系?   Java Slick2d如何将鼠标坐标转换为世界坐标   java内存泄漏。mysql。jdbc。ConnectionPropertiesImpl$*任意*ConnectionProperty   将java代码从hbase 0.92迁移到0.98.0hadoop2